@@ -1,204 +0,0 @@
-let mapleader =","
-
-if ! filereadable(expand('~/.config/nvim/autoload/plug.vim'))
- echo "Downloading junegunn/vim-plug to manage plugins..."
- silent !mkdir -p ~/.config/nvim/autoload/
- silent !curl "https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim" > ~/.config/nvim/autoload/plug.vim
-endif
-
-call plug#begin()
-Plug 'ap/vim-css-color' " highlight css colour codes with that color
-Plug 'vim-airline/vim-airline' " status bar
-Plug 'vim-airline/vim-airline-themes' " status bar themes
-Plug 'tpope/vim-surround' " highlight open/close characters like [], {}, ()
-Plug 'edkolev/tmuxline.vim' " apply vim statusbar theme to tmux
-Plug 'rhysd/vim-grammarous' " LanguageTool integration
-Plug 'wakatime/vim-wakatime' " Aggregate editor stats and metrics
-Plug 'fatih/vim-go', { 'do': ':GoUpdateBinaries' }
-Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'}
-call plug#end()
-
-lua <<EOF
-require'nvim-treesitter.configs'.setup {
- highlight = {
- enable = true,
- custom_captures = {
- -- Highlight the @foo.bar capture group with the "Identifier" highlight group.
- ["foo.bar"] = "Identifier",
- },
- -- Setting this to true will run `:h syntax` and tree-sitter at the same time.
- -- Set this to `true` if you depend on 'syntax' being enabled (like for indentation).
- -- Using this option may slow down your editor, and you may see some duplicate highlights.
- -- Instead of true it can also be a list of languages
- additional_vim_regex_highlighting = false,
- },
-}
-EOF
-lua <<EOF
-require'nvim-treesitter.configs'.setup {
- incremental_selection = {
- enable = true,
- keymaps = {
- init_selection = "gnn",
- node_incremental = "grn",
- scope_incremental = "grc",
- node_decremental = "grm",
- },
- },
-}
-EOF
-lua <<EOF
-require'nvim-treesitter.configs'.setup {
- indent = {
- enable = true
- }
-}
-EOF
-
-" LaTeX config
-let g:livepreview_previewer = 'zathura'
-let g:livepreview_use_biber = 1
-
-" Grammorous config
-let g:grammarous#languagetool_cmd = 'java -cp ~/languagetool/languagetool-server.jar org.languagetool.server.HTTPServer --port 8081 --allow-origin "*"'
-
-"packadd! dracula_pro
-"syntax enable
-"let g:dracula_colorterm = 0
-"colorscheme dracula_pro
-
-" syntastic settings
-set statusline+=%#warningmsg#
-set statusline+=%{SyntasticStatuslineFlag()}
-set statusline+=%*
-let g:syntastic_always_populate_loc_list = 1
-let g:syntastic_auto_loc_list = 1
-let g:syntastic_check_on_open = 1
-let g:syntastic_check_on_wq = 0
-
-""
-" Some basics
-""
-" Make ctags for supported languages
-command! MakeTags !ctags -R .
-" Add all subdirs to working path so :find works well
-set path+=**
-" Status line completion menu
-set wildmenu
-" Set above menu to a vertical instead of horizontal list
-set wildmode=full,list,full
-" Wrap long lines that continue past the viewport
-set linebreak
-" Highlight the column the cursor is on
-set cursorcolumn
-" Highlight the line the cursor is on
-set cursorline
-" Enables more colors
-set termguicolors
-" If there are folds, close some of them on startup
-set foldlevelstart=99
-" Use system clipboard for all yanking/pasting
-set clipboard+=unnamedplus
-" Use tabs but display them as 4 spaces instead of 8
-set ts=4 sts=4 sw=4 expandtab
-" Round the indent to a multiple of sw
-set shiftround
-" Set hidden character characters
-set listchars=tab:▸\ ,eol:¬,nbsp:␣,trail:•,space:.,extends:→,precedes:←
-set backspace=indent,eol,start
-" Keep 12 lines above and below the cursor when scrolling
-set scrolloff=12
-" Disable mouse support
-set mouse=
-" Use indents to determine folds
-set foldmethod=indent
-" Set line numbers relative to current line
-set number relativenumber
-" Show partial commands in the bottom right
-set showcmd
-" Show which mode you're in
-set showmode
-" Display partial matches when searching
-set incsearch
-" Highlight search results—hide with :noh
-set hlsearch
-" Wrap searches around the end of the file
-set wrapscan
-" Tell Vim to be more liberal with creating hidden buffers
-set hidden
-" Case-insensitive search unless term contains uppercase chars
-set smartcase
-
-" Statusbar theme
-let g:airline_powerline_fonts = 1
-let g:airline_theme='bubblegum'
-if !exists('g:airline_symbols')
- let g:airline_symbols = {}
-endif
-
-" Configure thesaurus
-let g:tq_mthesaur_file="~/.config/nvim/thesaurus/mthesaur.txt"
-let g:tq_enabled_backends=["datamuse_com","mthesaur_txt","openoffice_en"]
-
-""
-" Keybindings
-""
-" Insert timestamp at the end of the line in this format: 20200527T113245
-nnoremap <C-t><C-s> m'A<C-R>=strftime('%Y%m%dT%H%M%S')<CR>
-" Open a new tab
-nnoremap <C-t>t :tabnew<CR>
-" Toggle hidden characters
-nnoremap <C-l> :set list!<CR>
-
-" Window management
-map <C-h> <C-w>h
-map <C-j> <C-w>j
-map <C-k> <C-w>k
-map <C-l> <C-w>l
-
-" Snippets
-nnoremap ,nnm :read $HOME/.config/nvim/snippets/nnmail<CR>2jA
-nnoremap ,sig :read $HOME/.config/nvim/snippets/signature<CR>
-
-" only enable persistent undo if vim supports
-if has('persistent_undo')
- set undodir=$HOME/.config/nvim/undofile
- set undofile
-endif
-
-" Only enable autocommands when Vim supports them
-if has("autocmd")
- " Disables automatic commenting on newline:
- autocmd FileType * setlocal formatoptions-=c formatoptions-=r formatoptions-=o
-
- ""
- " File-specific indentation settings
- ""
- autocmd FileType make setlocal ts=8 sts=8 sw=8 noexpandtab
- autocmd FileType yaml setlocal ts=2 sts=2 sw=2 expandtab
-
- ""
- " Email configuration
- ""
- " Spellcheck in British English
- autocmd FileType eml setlocal spell spelllang=en_gb
- " Set lines to hard wrap at 72 chars
- autocmd FileType eml set tw=72
-
- ""
- " Markdown Configuration
- ""
- " Treat all .md files as markdown
- autocmd BufNewFile,BufRead *.md set filetype=markdown
- " Spellcheck in British English
- autocmd FileType markdown setlocal spell spelllang=en_gb
-
- ""
- " Working with LaTeX
- ""
- " Reduce udpatetime for faster previews
- autocmd BufNewFile,BufRead *.tex setfiletype tex
- autocmd FileType tex set ut=250
- autocmd FileType tex set colorcolumn=72
-
-endif