From 9e402cdd77837198043bd1e6f9516f1beadf3e65 Mon Sep 17 00:00:00 2001 From: Dominic Masters Date: Fri, 10 Dec 2021 19:54:15 +0000 Subject: [PATCH] Update VIM --- dotenv.sh | 6 ------ scripts/.vimrc | 19 ------------------- scripts/install-debian.sh | 4 +++- scripts/install-vim.sh | 12 ++++++++++++ scripts/vimrc-config | 27 +++++++++++++++++++++++++++ scripts/vimrc-plugins | 11 +++++++++++ 6 files changed, 53 insertions(+), 26 deletions(-) delete mode 100644 scripts/.vimrc create mode 100755 scripts/install-vim.sh create mode 100644 scripts/vimrc-config create mode 100644 scripts/vimrc-plugins diff --git a/dotenv.sh b/dotenv.sh index 5f044a9..bb34c87 100755 --- a/dotenv.sh +++ b/dotenv.sh @@ -22,9 +22,3 @@ fi # Node JS ./scripts/install-node.sh source ~/.nvm/nvm.sh - -# Install VIM Settings -curl -fLo ~/.vim/autoload/plug.vim --create-dirs \ - https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim -cp ./scripts/.vimrc ~/.vimrc -vim -c "PlugInstall" \ No newline at end of file diff --git a/scripts/.vimrc b/scripts/.vimrc deleted file mode 100644 index 0088571..0000000 --- a/scripts/.vimrc +++ /dev/null @@ -1,19 +0,0 @@ -call plug#begin('~/.vim/plugged') - -Plug 'tpope/vim-sensible' -Plug 'blackbirdtheme/vim' -Plug 'sheerun/vim-polyglot' -Plug 'epmor/hotline-vim' - -call plug#end() - -" Rules -set tabstop=2 -set et -%retab! - -" Colors -syntax enable -set background=dark -set background=dark -colorscheme blackbird \ No newline at end of file diff --git a/scripts/install-debian.sh b/scripts/install-debian.sh index 9814f62..e193a6e 100755 --- a/scripts/install-debian.sh +++ b/scripts/install-debian.sh @@ -5,4 +5,6 @@ sudo apt update sudo apt upgrade # Install -sudo apt install build-essential unrar vim git cmake +sudo apt install build-essential unrar vim git cmake neovim + +echo "alias vim=nvim" >> ~/.bashrc diff --git a/scripts/install-vim.sh b/scripts/install-vim.sh new file mode 100755 index 0000000..ea37c0c --- /dev/null +++ b/scripts/install-vim.sh @@ -0,0 +1,12 @@ +#!/bin/bash + +cd ./scripts + +# Install Plugin Manager +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' +cp ./vimrc-plugins ~/.config/nvim/init.vim +vim +"PlugInstall --sync" +qa + +# Setup Configuration +cat ./vimrc-config >> ~/.config/nvim/init.vim diff --git a/scripts/vimrc-config b/scripts/vimrc-config new file mode 100644 index 0000000..17f77ac --- /dev/null +++ b/scripts/vimrc-config @@ -0,0 +1,27 @@ +" General +set number +set linebreak +set showbreak=+++ +set textwidth=80 +set showmatch +set visualbell +set hlsearch +set smartcase +set ignorecase +set incsearch +set autoindent +set shiftwidth=2 +set smartindent +set smarttab +set softtabstop=2 +set et +%retab! + +set ruler +set undolevels=1000 +set backspace=indent,eol,start + +" Colors +syntax enable +set background=dark +colorscheme delek diff --git a/scripts/vimrc-plugins b/scripts/vimrc-plugins new file mode 100644 index 0000000..825dbd0 --- /dev/null +++ b/scripts/vimrc-plugins @@ -0,0 +1,11 @@ +call plug#begin('~/.vim/plugged') + +Plug 'tpope/vim-sensible' +Plug 'blackbirdtheme/vim' +"Plug 'sheerun/vim-polyglot' +"Plug 'epmor/hotline-vim' + +Plug 'preservim/nerdtree', { 'on': 'NERDTreeToggle' } + +call plug#end() +