autojump目录切换神器
autojump is a faster way to navigate your filesystem. It works by maintaining a database of the directories you use the most from the command line.
Directories must be visited first before they can be jumped to.
github地址:https://github.com/wting/autojump
官方Wiki:https://github.com/wting/autojump/wiki
之前写了mac如何安装autojump,觉得确实是一个神器,因此在Linux上安装,以此备用。
Ubuntu安装autojump
使用Ubuntu包管理apt进行安装:sudo apt install autojump
如果没有找到autojump包,则运行:sudo apt update
。
autojump支持的shell
通过安装autojump,在安装目录下找到支持的shell。
包括bash,fish,sh,zsh,软件默认安装在/usr/share/autojump
.
使用方法
查看默认使用的shell,或者设置其它shell为默认shell。cat $SHELL
例如Ubuntu默认shell为bash,则在~/.bashrc
中添加:source /usr/share/autojump/autojump.bash
例如打开文件夹即可使用j
加目录关键字打开。