about summary refs log tree commit diff stats
path: root/examples
diff options
context:
space:
mode:
Diffstat (limited to 'examples')
-rw-r--r--examples/fish_automatic_cd.fish5
1 files changed, 5 insertions, 0 deletions
diff --git a/examples/fish_automatic_cd.fish b/examples/fish_automatic_cd.fish
new file mode 100644
index 00000000..6c4d3536
--- /dev/null
+++ b/examples/fish_automatic_cd.fish
@@ -0,0 +1,5 @@
+# Note: funcsave save the alias in fish's config files, you do not need to copy
+# this file anywhere, just execute it once
+
+alias ranger-cd 'ranger --choosedir=$HOME/.rangerdir; set RANGERDIR (cat $HOME/.rangerdir); cd $RANGERDIR'
+funcsave ranger-cd