Open hacpai opened 9 years ago
If you are using bash, run this script:
echo ' [[ -s $(brew --prefix)/etc/profile.d/autojump.sh ]] && . $(brew --prefix)/etc/profile.d/autojump.sh' >> ~/.bashrc && source ~/.bashrc
For zsh or fish, just replace the profile name.
The correct way to do it is to run the following command:
Bash: echo "/usr/share/autojump/autojump.bash" >> ~/.bashrc
ZSH: echo "/usr/share/autojump/autojump.zsh" >> ~/.zshrc
Fish: echo "/usr/share/autojump/autojump.fish" >> ~/.fishrc
@varunagrawal
echo "/usr/share/autojump/autojump.zsh" >> ~/.zshrc
I guess you should source the file too, so it should be something like:
echo "source /usr/share/autojump/autojump.zsh" >> ~/.zhrc
For macOS, zsh:
Open ~/.zhrc:open .zhrc
Find "plugins=(git)"
Add the name of plugin you just install.
Then it will become "plugins=(git autojump)", just like this:
I hope this will help!
@iZhangZheng this only works if you are using oh-my-zsh or something else that handles plugins, it would for example be antigen bundle autojump
if you use zsh with antigen.
For macOS, zsh: Open ~/.zhrc:
open .zhrc
Find "plugins=(git)" Add the name of plugin you just install. Then it will become "plugins=(git autojump)", just like this:I hope this will help!
I suppose it should be ~/.zshrc ?
For anyone having this issue with bash on Ubuntu 18.04 (real machine or WSL), try this:
echo -e "# autojump\nsource /usr/share/autojump/autojump.bash" >> ~/.bashrc
Then reload your shell. Hope this helps!
For anyone having this issue with bash on Ubuntu 18.04 (real machine or WSL), try this:
echo -e "# autojump\nsource /usr/share/autojump/autojump.bash" >> ~/.bashrc
Then reload your shell. Hope this helps!
it worked for me ❤️ (using solus 4.1 and bash 5.0.11)
you can run brew info autojump
and see the command on it
eg:
My shell is fish-shell 2.1.1
OS is OS X 10.10.2