boxxy
v0.8.5
BoxXy(case敏感)是拳擊行為不當的Linux應用程序的工具,並迫使他們將文件和目錄放在正確的位置,而無需符號鏈接!
BoxXy是Amyware Discord服務器的一部分。
如果您喜歡我所做的,請考慮在Patreon上支持我:
僅限linux! BoxXy使用Linux名稱空間來實現其功能。
例如,考慮tmux。它希望將其配置放入~/.tmux.conf
中。使用BoxXy,您可以將其配置放入~/.config/tmux/tmux.conf
中:
# ~/.config/boxxy/boxxy.yaml
rules :
- name : " redirect tmux config from ~/.tmux.conf to ~/.config/tmux/tmux.conf "
target : " ~/.tmux.conf "
rewrite : " ~/.config/tmux/tmux.conf "
mode : " file "
由於健康原因,我正在休息一下開源項目。 PRS仍將被接受,並且仍將查看問題,但是何時發生這種情況並沒有承諾。
我最近不得不使用AWS CLI。它想要將數據保存在~/.aws
中,但是我不希望它只是在我的$HOME
上弄亂我的$。 Boxxy讓我強迫它將其數據放在一個不錯的位置。
0.5.0
:BoxXy可以掃描您的歸宿以自動為您建議規則!0.6.0
:BoxXy可以使用Project-Local boxxy.yaml
文件,並且可以為您加載.env
文件!0.6.1
:Boxxy規則可以注入env vars:0.7.2
:BoxXy可以用--daemon
標誌將框後的進程分配到背景中。0.8.0
:boxxy可以使用--rule
在命令行中傳遞規則,並使用--no-config
禁用加載配置文件。0.8.2
:說明如何正確運行適應性:git:(mistress) | ▶ cat ~ /.config/boxxy/boxxy.yaml
rules:
- name: " Store AWS CLI config in ~/.config/aws "
target: " ~/.aws "
rewrite: " ~/.config/aws "
git:(mistress) | ▶ boxxy aws configure
INFO boxxy > loaded 1 rules
INFO boxxy::enclosure > applying rule ' Store AWS CLI config in ~/.config/aws '
INFO boxxy::enclosure > redirect: ~ /.aws - > ~ /.config/aws
INFO boxxy::enclosure > boxed " aws " ♥
AWS Access Key ID [ **************** d]: a
AWS Secret Access Key [ **************** c]: b
Default region name [b]: c
Default output format [a]: d
git:(mistress) | ▶ ls ~ /.aws
git:(mistress) | ▶ ls ~ /.config/aws
config credentials
git:(mistress) | ▶ cat ~ /.config/aws/config
[default]
region = c
output = d
git:(mistress) | ▶
alias aws="boxxy aws"
(重複其他工具)BoxXy需要newuidmap
才能函數,默認情況下並未包含在所有分佈中。安裝:
Alpine:
$ apk add shadow-uidmap
Debian / Ubuntu:
$ apt install uidmap
Rhel / Fedora:
$ yum install shadow-utils
boxxy配置文件屬於~/.config/boxxy/boxxy.yaml
。如果不存在,將為您創建一個空的。
rules :
# The name of the rule. User-friendly name for your reference
- name : " redirect aws-cli from ~/.aws to ~/.config/aws "
# The target of the rule, ie the file/directory that will be shadowed by the
# rewrite.
target : " ~/.aws "
# The rewrite of the rule, ie the file/directory that will be used instead of
# the target.
rewrite : " ~/.config/aws "
- name : " use different k8s configs when in ~/Projects/my-cool-startup "
target : " ~/.kube/config "
rewrite : " ~/Projects/my-cool-startup/.kube/config "
# The context for the rule. Any paths listed in the context are paths where
# this rule will apply. If no context is specified, the rule applies
# globally.
context :
- " ~/Projects/my-cool-startup "
# The mode of this rule, either `directory` or `file`. `directory` is the
# default. Must be specified for the correct behaviour when the target is a
# file. Required because the target file/directory may not exist yet.
mode : " file "
# The list of commands that this rule applies to. If no commands are
# specified, the rule applies to all programs run with boxxy.
only :
- " kubectl "
rules :
- name : " any valid string " # required
target : " path " # required
rewrite : " path " # required
context : # optional
- " path "
- " path "
mode : " directory | file " # optional
only : # optional
- " binary name "
- " binary name "
env : # optional
KEY : " value "
pre-commit install
cargo build
cargo run -- ls -lah ~/.config
/
與TMP目錄/
rofixtures/helloworld-appimage-x86_84.AppImage
:https://github.com/clonedrepos/hello-world-pappimage