Updated zsh config
This commit is contained in:
@@ -20,7 +20,6 @@
|
||||
pk = "pkill -9 -f";
|
||||
svcu = "systemctl --user";
|
||||
svc = "sudo systemctl";
|
||||
viflake = "nvim flake.nix";
|
||||
iv = "invoke";
|
||||
cfgfilecount = ''find ".\.nix" $FLAKEPATH | wc -l | toilet -f 3d | lolcat'';
|
||||
record = "wf-recorder";
|
||||
@@ -33,6 +32,10 @@
|
||||
rsh = "$HOME/Coding/projects/rust/rsh/target/debug/rsh";
|
||||
vide = "neovide";
|
||||
pk9 = "pkill -9";
|
||||
mkexe = "chmod +x";
|
||||
shortdate = "date '+%m-%d-%y'";
|
||||
suvi = "sudoedit";
|
||||
suvide = "EDITOR=neovide; suvi";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
BROWSER = "firefox";
|
||||
FLAKEPATH = "$HOME/.sysflake";
|
||||
STEAMPATH = "$HOME/.local/share/Steam";
|
||||
TFPATH = "$STEAMPATH/steamapps/common/Team Fortress 2/";
|
||||
PATH = "$PATH:$HOME/.userpath/";
|
||||
FZF_DEFAULT_COMMAND = "fd";
|
||||
FZF_DEFAULT_OPTS = "--height 40% --layout=reverse --border";
|
||||
|
||||
@@ -34,6 +34,18 @@ in
|
||||
nsp() {
|
||||
NIX_SHELL=true command nix-shell -p "$@" --run zsh
|
||||
}
|
||||
viflake() {
|
||||
(
|
||||
while ! [ -f ./flake.nix ]; do
|
||||
builtin cd ..
|
||||
if [ "$PWD" = "/" ]; then
|
||||
echo "No flake.nix found in this directory, or any parent directories."
|
||||
return 1
|
||||
fi
|
||||
done
|
||||
nvim ./flake.nix
|
||||
)
|
||||
}
|
||||
nvim() {
|
||||
${shellsound} ${sndpath}/nvim.wav
|
||||
command nvim "$@"
|
||||
@@ -185,7 +197,7 @@ in
|
||||
eval "$(starship init zsh)"
|
||||
}
|
||||
${shellsound} ${sndpath}/sh-source.wav
|
||||
[ ! -f $FLAKEPATH/flake.nix ] && echo "WARNING: flake.nix not found at \$FLAKEPATH. Shell aliases for editing config files won't work correctly!" && echo "Edit the FLAKEPATH session variable in zshell.nix to point to the path where you saved the system configuration flake."
|
||||
[ ! -f $FLAKEPATH/flake.nix ] && echo "WARNING: flake.nix not found at \$FLAKEPATH. Shell aliases for editing config files won't work correctly!" && echo "Edit the FLAKEPATH session variable in zsh/env.nix to point to the path where you saved the system configuration flake."
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user