summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChloƩ Vulquin <code@toast.bunkerlabs.net>2024-04-21 10:50:37 +0200
committerChloƩ Vulquin <code@toast.bunkerlabs.net>2024-04-21 10:50:37 +0200
commitf3114bcaede1bc80ed3f3194b3de9e3e7af0e5fa (patch)
treeab8344093f73e752ef8117dbe41185fc55b7187f
parentnvim/conjure: use stdio for janet (diff)
sh/zoxide: also alias cd
To my knowledge there's no advantage to the builtin over `z`. Maybe syntax highlighting? Anyway I forget to type `z` pretty often, so just alias cd.
-rw-r--r--dot_local/share/sh/zoxide1
-rw-r--r--dot_local/share/sh/zoxide.bash1
-rw-r--r--dot_local/share/sh/zoxide.fish3
3 files changed, 5 insertions, 0 deletions
diff --git a/dot_local/share/sh/zoxide b/dot_local/share/sh/zoxide
index 210db16..a89202c 100644
--- a/dot_local/share/sh/zoxide
+++ b/dot_local/share/sh/zoxide
@@ -1,2 +1,3 @@
. hascmd zoxide || return
eval "$(zoxide init posix --hook prompt)"
+alias cd=z
diff --git a/dot_local/share/sh/zoxide.bash b/dot_local/share/sh/zoxide.bash
index 6a02524..b3ab493 100644
--- a/dot_local/share/sh/zoxide.bash
+++ b/dot_local/share/sh/zoxide.bash
@@ -1,2 +1,3 @@
. hascmd zoxide || return
eval "$(zoxide init bash)"
+alias cd=z
diff --git a/dot_local/share/sh/zoxide.fish b/dot_local/share/sh/zoxide.fish
index b62450c..6c97910 100644
--- a/dot_local/share/sh/zoxide.fish
+++ b/dot_local/share/sh/zoxide.fish
@@ -1,2 +1,5 @@
. hascmd zoxide || return
zoxide init fish | source
+function cd --wraps=z --description 'alias cd=z'
+ z $argv
+end