From 255fba2de55f34f7c183becb868017026d6dd024 Mon Sep 17 00:00:00 2001 From: pagedmov Date: Tue, 29 Oct 2024 23:56:36 -0400 Subject: [PATCH] removed mcd.nix script and added it as a function to zshell.nix --- modules/home/environment/zshell.nix | 4 ++++ modules/home/scripts/commands/mcd.nix | 11 ----------- modules/home/scripts/default.nix | 5 ----- 3 files changed, 4 insertions(+), 16 deletions(-) delete mode 100644 modules/home/scripts/commands/mcd.nix diff --git a/modules/home/environment/zshell.nix b/modules/home/environment/zshell.nix index b48756c..5b75403 100644 --- a/modules/home/environment/zshell.nix +++ b/modules/home/environment/zshell.nix @@ -114,6 +114,10 @@ return 0 } + mkcd() { + mkdir -p "$1" && cd "$1" + } + y() { local tmp="$(mktemp -t "yazi-cwd.XXXXXX")" yazi "$@" --cwd-file="$tmp" diff --git a/modules/home/scripts/commands/mcd.nix b/modules/home/scripts/commands/mcd.nix deleted file mode 100644 index 85c5636..0000000 --- a/modules/home/scripts/commands/mcd.nix +++ /dev/null @@ -1,11 +0,0 @@ -{ - self, - pkgs, -}: -pkgs.writeShellScriptBin "mcd" '' - #!/run/current-system/sw/bin/bash - - - mkdir -p "$1" - cd "$1" || exit -'' diff --git a/modules/home/scripts/default.nix b/modules/home/scripts/default.nix index 0eae9e8..bbaf3fa 100644 --- a/modules/home/scripts/default.nix +++ b/modules/home/scripts/default.nix @@ -24,10 +24,6 @@ self = self; pkgs = pkgs; }; - mcd = import ./commands/mcd.nix { - self = self; - pkgs = pkgs; - }; garbage-collect = import ./nix/garbage-collect.nix { self = self; pkgs = pkgs; @@ -61,7 +57,6 @@ in { keyring garbage-collect invoke - mcd rebuild nsp runbg