diff --git a/.bash_aliases b/.bash_aliases index 0a701e0..61cf3a4 100644 --- a/.bash_aliases +++ b/.bash_aliases @@ -1,8 +1,10 @@ # Custom aliases for ntnsndr # Be sure this is referred to in .bashrc +set -o vi + # More or less permanent file aliases: -alias Proximate='emacs ~/Cloud/Notes/Proximate.md' +alias Proximate='nvim ~/Cloud/Notes/Proximate.md' alias Finances='less ~/Cloud/Current/School/Finances.md' # More or less permanent directory aliases: @@ -20,13 +22,14 @@ alias cv='~/.scripts/cv.sh' alias dotupdate='git fetch --all && git reset --hard origin/master' alias pandout='~/.scripts/pandout.sh' alias pandorm='rm -rf output' +alias panda='~/.scripts/panda.sh' # Hopefully temporary utility aliases: alias paren='xmodmap -e "keycode 81=9 parenleft"' # More or less permanent utility aliases: alias emacs='emacs -nw' -alias editalias='emacs ~/.bash_aliases' +alias editalias='nvim ~/.bash_aliases' alias open='xdg-open' alias rm='rm -i' -alias search='grep -i' \ No newline at end of file +alias search='grep -i' diff --git a/.scripts/install-arch.sh b/.scripts/install-arch.sh index b8b4d77..905a072 100755 --- a/.scripts/install-arch.sh +++ b/.scripts/install-arch.sh @@ -28,6 +28,10 @@ sudo pacman -S emacs sudo pacman -S aspell-en # English dictionary emacs --script ~/.scripts/install-emacs.el +# nvim +sudo pacman -S neovim +~/.scripts/install-vim.sh + # pandoc sudo pacman -S pandoc sudo pacman -S texlive-core diff --git a/.scripts/install-deb.sh b/.scripts/install-deb.sh index 1c6ec88..7cccc23 100755 --- a/.scripts/install-deb.sh +++ b/.scripts/install-deb.sh @@ -18,6 +18,10 @@ sudo apt -y install emacs-gtk sudo apt -y install aspell aspell-en emacs --script ~/.scripts/install-emacs.el +# nvim +sudo apt -y install neovim +~/.scripts/install-vim.sh + # pandoc sudo apt -y install texlive sudo apt -y install texlive-latex-extra diff --git a/.scripts/install-vim.sh b/.scripts/install-vim.sh index 46a1169..428697a 100644 --- a/.scripts/install-vim.sh +++ b/.scripts/install-vim.sh @@ -1,5 +1,4 @@ - -# TODO have to clarify how to set the location of the .vimrc file +# Set up nvim # create symbolic link to the .vimrc mkdir -p ~/.config/nvim @@ -9,5 +8,5 @@ ln -s ~/.vimrc ~/.config/nvim/init.vim 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' -# TODO have to make sure to install the plugins - +# install plugins +nvim -c "PlugInstall" -c "q" diff --git a/.vimrc b/.vimrc index 9674136..aff9e68 100644 --- a/.vimrc +++ b/.vimrc @@ -3,22 +3,39 @@ " Basics syntax on set noerrorbells -set tabstop=4 softtabstop=4 -set linebreak -set wrap -nnoremap :set linebreak -nnoremap :set nolinebreak -set incsearch set spell +" Line wrapping in Markdown files +autocmd FileType markdown setlocal linebreak +autocmd FileType markdown noremap j gj +autocmd FileType markdown noremap k gk + +" Tabs +set tabstop=4 +set shiftwidth=4 +set expandtab + +"Search +set ic +set smartcase +set incsearch + " Workspace location let g:workspace_session_directory = $HOME . '/.vim/sessions/' +" Set shell to bash +set shell=bash\ -l + +" Shortcuts +command! Proximate :e ~/Cloud/Notes/Proximate.md + +" Create panda command for pandout +command! -nargs=1 Panda :!~/.scripts/panda.sh % + " Plugins call plug#begin() -"Plug 'plasticboy/vim-markdown' Plug 'junegunn/goyo.vim' -Plug 'reedes/vim-pencil' -Plug 'vim-pandoc/vim-pandoc' +"Plug 'plasticboy/vim-markdown' +"Plug 'vim-pandoc/vim-pandoc' "Plug 'vim-pandoc/vim-pandoc-syntax' call plug#end()