autojump linux command line tool

Are you still troubled by the frequent use of the cd command to switch folders in Linux?

Are you still worrying about finding a folder and frequently cd switching folders and then ls or ll?

Are you still...

Who knows why and what you are still...

But as long as you have this tool autojump, you will no longer be troubled/annoyed/whatever....

 

1. Installation:

First download the tool in the required directory, we pull it directly from git:

git clone git://github.com/joelthelion/autojump.git

2: Installation tools

./autojump/install.py 

3. The prompt information after installation can be seen:

Please manually add the following line(s) to ~/.bashrc:

	[[ -s /root/.autojump/etc/profile.d/autojump.sh ]] && source /root/.autojump/etc/profile.d/autojump.sh

Please restart terminal(s) before running autojump.

Then we follow the prompts:

vim ~/.bashrc 

Copy the above tips to a location, as follows:

#set for autojump
[[ -s /root/.autojump/etc/profile.d/autojump.sh ]] && source /root/.autojump/etc/profile.d/autojump.sh

To make it work:

source ~/.bashrc

4. Check if the installation is successful:

j -v

If you see the version number, it means that the installation was successful, and you can use it unscrupulously;

5. Working principle:

autojump itself maintains a database, which will be stored whenever you cd, so if the directory you want to go to has not been cd into, using the j command is invalid;

6.demo:

[root@localhost autojump]# cd /
[root@localhost /]# cd etc/software/autojump/
[root@localhost autojump]# cd /
[root@localhost /]# j auto__
/etc/software/autojump
[root@localhost autojump]# cd /
[root@localhost /]# j /
/etc/software/autojump

 

 

 

 

 

 

For its attributes, please refer to the article: https://linux.cn/article-3401-1.html#3_852

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325566647&siteId=291194637