重构个人配置结构

This commit is contained in:
2026-05-17 10:24:49 +08:00
parent 5072597827
commit 658910097b
10 changed files with 37 additions and 71 deletions
+16
View File
@@ -1,5 +1,21 @@
#!/usr/bin/env zsh
if command -v direnv &> /dev/null; then
eval "$(direnv hook zsh)"
fi
o4-nixos-switch() {
if [[ "$(uname)" == "Darwin" ]]; then
darwin-rebuild switch --flake ~/flakes#$(hostname)
else
nixos-rebuild switch --use-remote-sudo --flake ~/flakes#$(hostname)
fi
}
o4-home-switch() {
home-manager switch --flake ~/flakes#$(whoami)@$(hostname)
}
sops-update-file() {
local src_file="$1"
local yaml_file="$2"