Code Yarns ‍👨‍💻
Tech BlogPersonal Blog

How to install autojump for Fish

📅 2014-Feb-27 ⬩ ✍️ Ashwin Nanjappa ⬩ 🏷️ autojump, fish ⬩ 📚 Archive

Autojump is a tool that can be used to jump around in the shell to frequently used directories by typing just a part of their name. It is typically aliased to j. Autojump is available as a package in the Ubuntu repositories, but that is an old version that does not support the fish shell. Installing the latest version for fish is pretty easy:

$ git clone https://github.com/wting/autojump.git
$ cd autojump
$ ./install.py
begin
    set --local AUTOJUMP_PATH $HOME/.autojump/share/autojump/autojump.fish
    if test -e $AUTOJUMP_PATH
        source $AUTOJUMP_PATH
    end
end
$ cd /some/superlongdirectoryname
$ cd
$ j tory
$ pwd
/some/superlongdirectoryname
$ jc some_blah
$ j -s

Tried with: Autojump 22.2.4, Fish 2.2b1 and Ubuntu 14.04


© 2022 Ashwin Nanjappa • All writing under CC BY-SA license • 🐘 @codeyarns@hachyderm.io📧