Updated zsh config

This commit is contained in:
2025-07-29 14:33:37 -04:00
parent 44062a87b4
commit 4e44a1618b
6 changed files with 69 additions and 56 deletions

View File

@@ -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";
};
};
};

View File

@@ -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";

View File

@@ -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."
'';
};
};

View File

@@ -9,7 +9,7 @@
font = {
package = lib.mkForce pkgs.nerd-fonts.envy-code-r;
name = lib.mkForce "EnvyCodeR Nerd Font Mono";
size = lib.mkForce 20;
size = lib.mkForce 19;
};
settings = {