added a script to install nvim

This commit is contained in:
Daniel Knüttel 2021-02-25 20:35:22 +01:00
parent 3373f5c49e
commit a5e3d7f440
1 changed files with 23 additions and 0 deletions

23
install_nvim.sh Executable file
View File

@ -0,0 +1,23 @@
#!/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\""