custom file for run alias

This commit is contained in:
valerie 2024-10-10 19:42:00 -04:00
parent 099ff05405
commit f4d91a0af7
Signed by: valnyx
GPG key ID: CC10324DD962CB7E
2 changed files with 8 additions and 1 deletions

5
home/dotfiles/run Normal file
View file

@ -0,0 +1,5 @@
if [[ -z "$2" ]]; then
nix-shell -p $1 --run zsh
else
nix-shell -p $1 --run "$2"
fi

View file

@ -5,6 +5,7 @@
... ...
}: let }: let
pst = pkgs.writeShellScriptBin "pst" (builtins.readFile ../../dotfiles/pst); pst = pkgs.writeShellScriptBin "pst" (builtins.readFile ../../dotfiles/pst);
runpkg = pkgs.writeShellScriptBin "run" (builtins.readFile ../../dotfiles/run);
in { in {
xdg.configFile."wezterm/colors/camellia-hope-dark.toml".text = builtins.readFile (pkgs.fetchFromGitHub { xdg.configFile."wezterm/colors/camellia-hope-dark.toml".text = builtins.readFile (pkgs.fetchFromGitHub {
owner = "camellia-theme"; owner = "camellia-theme";
@ -375,7 +376,8 @@ in {
shellAliases = { shellAliases = {
tm = "tmuxifier"; tm = "tmuxifier";
t = "tmux"; t = "tmux";
run = "nix-shell --command 'zsh' -p"; # run = "nix-shell --command 'zsh' -p";
run = "${runpkg}/bin/run";
fhs = "steam-run"; fhs = "steam-run";
nsh = "nix-shell --command 'zsh'"; nsh = "nix-shell --command 'zsh'";
nd = "nix develop"; nd = "nix develop";