# autocompletion file in the first directory of the FPATH variable
if( ! ${local});then
fail=true
for f in $fpath
do
cp _j $f&&fail=false&& break
done
if$fail
then
echo"Couldn't find a place to put the autocompletion file, please copy _j into your \$fpath"
echo"Still trying to install the rest of autojump..."
else
echo"Installed autocompletion file to $f"
fi
fail=true
for f in $fpath
do
cp _j $f&&fail=false&& break
done
if$fail
then
echo"Couldn't find a place to put the autocompletion file, please copy _j into your \$fpath"
echo"Still trying to install the rest of autojump..."
else
echo"Installed autocompletion file to $f"
fi
if[ -d "/etc/profile.d"];then
cp -v autojump.zsh /etc/profile.d/
cp -v autojump.sh /etc/profile.d/
echo
echo"Add the following line to your ~/.zshrc:"
echo
echo -e "\tsource /etc/profile.d/autojump.zsh"
echo
echo"You need to source your ~/.zshrc (source ~/.zshrc) before you can start using autojump."
else
echo"Your distribution does not have a /etc/profile.d directory, the default that we install one of the scripts to. Would you like us to copy it into your ~/.zshrc file to make it work? (If you have done this once before, delete the old version before doing it again.) [y/n]"
echo"You need to source your ~/.zshrc (source ~/.zshrc) before you can start using autojump."
else
echo"Then you need to put autojump.zsh, or the code from it, somewhere where it will get read. Good luck!"
fi
else
echo"Then you need to put autojump.zsh, or the code from it, somewhere where it will get read. Good luck!"
fi
fi
if[ -d "/etc/profile.d"];then
cp -v autojump.zsh /etc/profile.d/
cp -v autojump.sh /etc/profile.d/
echo
echo"Add the following line to your ~/.zshrc:"
echo
echo -e "\tsource /etc/profile.d/autojump.zsh"
echo
echo"You need to source your ~/.zshrc (source ~/.zshrc) before you can start using autojump."
echo
if[[${prefix} !="/usr"]];then
echo"To remove autojump, run ./uninstall.zsh --prefix ${prefix}"
else
echo"To remove autojump, run ./uninstall.zsh"
fi
else
echo"Your distribution does not have a /etc/profile.d directory, the default that we install one of the scripts to. Would you like us to copy it into your ~/.zshrc file to make it work? (If you have done this once before, delete the old version before doing it again.) [y/n]"