neovim-config/install_nvim.sh

24 lines
775 B
Bash
Raw Normal View History

2021-02-25 19:35:22 +00:00
#!/bin/bash
installdir="$HOME/.local/bin"
echo "install directory is $installdir"
if [ ! -d $installdir ]; then
echo "install directory does not exist, creating it"
mkdir -p $installdir || (echo "failed to create install directory" ; exit 1)
fi
cd $installdir
echo "downloading appimage..."
wget https://github.com/neovim/neovim/releases/download/nightly/nvim.appimage || (echo "failed to download appimage"; exit 1)
echo "done."
chmod +x nvim.appimage
echo "The neovim appimage has been downloaded into $installdir."
echo "It has been marked as executable, you can now run $installdir/nvim.appimage."
echo "You should add an alias into your shrc:"
echo " alias vim=\"$installdir/nvim.appimage\""
echo "or"
echo " alias nvim=\"$installdir/nvim.appimage\""