Last active
October 27, 2021 06:16
-
-
Save AstralJohn/2a9b83fc9ed5b7f2847fc1a36c308940 to your computer and use it in GitHub Desktop.
jeff nvim install
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
username=result=${PWD##*/} | |
add-apt-repository ppa:neovim-ppa/unstable # neovim ppa | |
echo "Installing git..." | |
if ! command -v git &> /dev/null # install node if it isn't already | |
then | |
apt install git | |
fi | |
echo "Installing nodejs..." | |
if ! command -v node &> /dev/null # install node if it isn't already | |
then | |
# add node ppa | |
curl -sL https://deb.nodesource.com/setup_16.x | bash | |
apt update | |
apt upgrade | |
apt install nodejs | |
fi | |
echo "Installing npm..." | |
if ! command -v npm &> /dev/null # install npm if it isn't already | |
then | |
apt install npm | |
fi | |
echo "Installing neovim..." | |
if ! command -v nvim &> /dev/null # install neovim if it isn't already | |
then | |
apt install neovim | |
fi | |
INIT_VIM="./.config/nvim/init.vim" | |
mkdir .config/nvim | |
touch .config/nvim/init.vim | |
curl https://gist.githubusercontent.com/JohnDinhDev/9cdf72ac2e7bc7587ba83237ae91070d/raw/1cfb4773000c262cc35f8b2902ff2202eb59b83c/gistfile1.txt > "./.config/nvim/init.vim" | |
echo "Your pp smoll, but neovim is now installed" | |
echo "====================" | |
echo " IMPORTANT" | |
echo "====================" | |
echo "To complete the installation, these next steps have to be done manually." | |
echo "copy and paste this block of code into your terminal | |
" | |
echo "sh -c 'curl -fLo \"\${XDG_DATA_HOME:-\$HOME/.local/share}\"/nvim/site/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim' | |
" | |
echo "then run nvim, (there will be a lot of errors, hit the return key to ignore them all) then inside of nvim type ":PlugInstall" to complete installation." |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment