Update nvim.
This commit is contained in:
parent
95f6175bb1
commit
a6674ca61d
|
|
@ -1,3 +1,8 @@
|
|||
augroup vyper_ft
|
||||
au!
|
||||
autocmd BufNewFile,BufRead *.vy set syntax=vyper
|
||||
augroup END
|
||||
|
||||
" Set tabs for certain file types
|
||||
" for html and css js and vue
|
||||
autocmd FileType html setlocal ts=2 sw=2 expandtab
|
||||
|
|
@ -28,8 +33,10 @@ autocmd BufWritePost config.h,config.def.h !sudo make install; make clean
|
|||
" Comile any latex document into pdf form
|
||||
autocmd BufWritePost answers.tex !pdflatex answers.tex
|
||||
|
||||
" Compile VIU markdown notes to pdf
|
||||
autocmd BufWritePost notes.md !pandoc -s -o notes.pdf notes.md
|
||||
" Compile markdown notes to pdf
|
||||
" This is fucking cool but also requires a bunch on dependencies on popos.
|
||||
" requires pandoc and texlive-latex-base
|
||||
"autocmd BufWritePost notes.md !pandoc -s -o notes.pdf notes.md
|
||||
|
||||
" clear empty spaces at the end of lines on save of python files
|
||||
"autocmd BufWritePre *.py :%s/\s\+$//e
|
||||
|
|
|
|||
|
|
@ -931,6 +931,7 @@
|
|||
"description": "Set to false to disable snippets support.",
|
||||
"default": true
|
||||
},
|
||||
"coc.source.emoji.filetypes": ["markdown","python"],
|
||||
"coc.source.around.enable": {
|
||||
"type": "boolean",
|
||||
"default": true
|
||||
|
|
@ -1059,6 +1060,7 @@
|
|||
"sigint",
|
||||
"trainsets"
|
||||
],
|
||||
"clangd.path": "/home/matt/.config/coc/extensions/coc-clangd-data/install/10.0.0/clangd_10.0.0/bin/clangd"
|
||||
"clangd.path": "/home/matt/.config/coc/extensions/coc-clangd-data/install/10.0.0/clangd_10.0.0/bin/clangd",
|
||||
"snippets.ultisnips.pythonPrompt": false
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,90 @@
|
|||
" taken from bat:
|
||||
let b:outer_space="#263238" " dark blue (background colour)
|
||||
let b:spring_wood="#f8f8f0" " very light yellow
|
||||
let b:sunshade="#fe8a26" " orange
|
||||
let b:malibu="#62d6fd" " light blue
|
||||
let b:pear="#a6e22e" " light green
|
||||
let b:carnation="#f36464" " light red
|
||||
let b:heliotrope="#be84ff" " light purple
|
||||
|
||||
" other (taken from molokai):
|
||||
let b:tundora="#444444" " dark gray
|
||||
let b:mine_shaft="#373737" " very dark gray
|
||||
let b:storm_dust="#60605e" " yet another shade of gray
|
||||
|
||||
" customised:
|
||||
let b:sirocco="#747e80" " gray (used for comments)
|
||||
let b:yellow="#ffff00" " pure yellow
|
||||
|
||||
set background=dark
|
||||
highlight clear
|
||||
|
||||
if exists("syntax_on")
|
||||
syntax reset
|
||||
endif
|
||||
|
||||
let g:colors_name = "bat"
|
||||
|
||||
function! s:hi(name, fg, bg, gui)
|
||||
execute 'hi' a:name "ctermfg=NONE" "ctermbg=NONE" ("guifg=".a:fg) ("guibg=".a:bg) ("gui=".a:gui)
|
||||
endfunction
|
||||
|
||||
call s:hi("Cursor", b:outer_space, b:spring_wood, "NONE")
|
||||
call s:hi("Visual", "NONE", b:tundora, "NONE")
|
||||
call s:hi("CursorLine", "NONE", b:mine_shaft, "NONE")
|
||||
call s:hi("CursorColumn", "NONE", b:mine_shaft, "NONE")
|
||||
call s:hi("ColorColumn", "NONE", b:mine_shaft, "NONE")
|
||||
call s:hi("LineNr", b:sirocco, b:mine_shaft, "NONE")
|
||||
call s:hi("VertSplit", b:storm_dust, b:storm_dust, "NONE")
|
||||
call s:hi("MatchParen", b:malibu, "NONE", "underline")
|
||||
call s:hi("StatusLine", b:spring_wood, b:storm_dust, "bold")
|
||||
call s:hi("StatusLineNC", b:spring_wood, b:storm_dust, "NONE")
|
||||
call s:hi("Pmenu", "white", b:tundora, "NONE")
|
||||
call s:hi("PmenuSel", "NONE", b:outer_space, "NONE")
|
||||
call s:hi("IncSearch", b:outer_space, b:yellow, "NONE")
|
||||
call s:hi("Search", b:outer_space, b:yellow, "NONE")
|
||||
call s:hi("Directory", b:heliotrope, "NONE", "NONE")
|
||||
call s:hi("Folded", b:tundora, b:outer_space, "NONE")
|
||||
call s:hi("Normal", b:spring_wood, b:outer_space, "NONE")
|
||||
call s:hi("Boolean", b:heliotrope, "NONE", "NONE")
|
||||
call s:hi("Character", b:heliotrope, "NONE", "NONE")
|
||||
call s:hi("Comment", b:sirocco, "NONE", "NONE")
|
||||
call s:hi("Conditional", b:carnation, "NONE", "NONE")
|
||||
call s:hi("Constant", "NONE", "NONE", "NONE")
|
||||
call s:hi("Define", b:malibu, "NONE", "NONE")
|
||||
call s:hi("ErrorMsg", b:spring_wood, b:malibu, "NONE")
|
||||
call s:hi("WarningMsg", b:spring_wood, b:malibu, "NONE")
|
||||
call s:hi("Float", b:heliotrope, "NONE", "NONE")
|
||||
call s:hi("Function", b:pear, "NONE", "NONE")
|
||||
call s:hi("Identifier", b:sunshade, "NONE", "NONE")
|
||||
call s:hi("Include", b:carnation, "NONE", "NONE")
|
||||
call s:hi("Keyword", b:malibu, "NONE", "NONE")
|
||||
call s:hi("Label", "#e6db74", "NONE", "NONE")
|
||||
call s:hi("NonText", b:mine_shaft, b:outer_space, "NONE")
|
||||
call s:hi("Number", b:heliotrope, "NONE", "NONE")
|
||||
call s:hi("Operator", b:carnation, "NONE", "NONE")
|
||||
call s:hi("PreProc", b:malibu, "NONE", "NONE")
|
||||
call s:hi("TSProperty", "white", "NONE", "NONE")
|
||||
call s:hi("Special", "#af87fc", "NONE", "NONE")
|
||||
call s:hi("SpecialKey", b:mine_shaft, "NONE", "NONE")
|
||||
call s:hi("Statement", b:carnation, "NONE", "NONE")
|
||||
call s:hi("StorageClass", "#66d9ef", "NONE", "NONE")
|
||||
call s:hi("String", "#ffd242", "NONE", "NONE")
|
||||
call s:hi("Tag", b:malibu, "NONE", "NONE")
|
||||
call s:hi("Title", b:spring_wood, "NONE", "bold")
|
||||
call s:hi("Todo", "#75715e", "#8cd0de", "bold")
|
||||
call s:hi("Type", b:pear, "NONE", "NONE")
|
||||
call s:hi("Underlined", "NONE", "NONE", "underline")
|
||||
call s:hi("DiffAdd", b:spring_wood, "#45820c", "bold")
|
||||
call s:hi("DiffDelete", "#8a0707", "NONE", "NONE")
|
||||
call s:hi("DiffChange", b:spring_wood, "#213655", "NONE")
|
||||
call s:hi("DiffText", b:spring_wood, "#204a87", "bold")
|
||||
" vim-go:
|
||||
call s:hi("goReceiverVar", b:sunshade, "NONE", "NONE")
|
||||
call s:hi("goParamName", b:sunshade, "NONE", "NONE")
|
||||
call s:hi("goReceiverType", b:malibu, "NONE", "NONE")
|
||||
call s:hi("goFunctionCall", b:spring_wood, "NONE", "NONE")
|
||||
call s:hi("goVarDefs", b:spring_wood, "NONE", "NONE")
|
||||
call s:hi("goVarAssign", b:spring_wood, "NONE", "NONE")
|
||||
call s:hi("goBuiltins", b:malibu, "NONE", "NONE")
|
||||
|
||||
|
|
@ -16,8 +16,8 @@ let g:quantum_black = get(g:, 'quantum_black', 0)
|
|||
|
||||
" Color Palette
|
||||
let s:gray1 = g:quantum_black ? '#000000' : '#000'
|
||||
let s:gray2 = g:quantum_black ? '#292929' : '#2c3a41'
|
||||
let s:gray3 = g:quantum_black ? '#474646' : '#425762'
|
||||
let s:gray2 = g:quantum_black ? '#393939' : '#2c3a41'
|
||||
let s:gray3 = g:quantum_black ? '#565656' : '#425762'
|
||||
let s:gray4 = g:quantum_black ? '#6a6c6c' : '#658494'
|
||||
let s:gray5 = g:quantum_black ? '#b7bdc0' : '#aebbc5'
|
||||
let s:red = '#dd7186'
|
||||
|
|
@ -85,7 +85,7 @@ call s:HL('TabLineSel', s:yellow, s:gray3, 'none')
|
|||
call s:HL('Title', s:green, '', 'none')
|
||||
call s:HL('VertSplit', s:gray4, s:gray1, 'none')
|
||||
call s:HL('Visual', s:gray5, s:gray3, '')
|
||||
call s:HL('WarningMsg', s:red, '', '')
|
||||
call s:HL('WarningMsg', s:red, '', 'bold')
|
||||
call s:HL('WildMenu', s:gray2, s:cyan, '')
|
||||
|
||||
" Standard Syntax
|
||||
|
|
|
|||
|
|
@ -0,0 +1,7 @@
|
|||
" my filetype file
|
||||
if exists("did_load_filetypes")
|
||||
finish
|
||||
endif
|
||||
augroup filetypedetect
|
||||
au! BufRead,BufNewFile *.vy setfiletype python
|
||||
augroup END
|
||||
|
|
@ -46,3 +46,6 @@ nnoremap <M-a> <home>
|
|||
:set cursorline
|
||||
:set number
|
||||
:set relativenumber!
|
||||
:set autoread
|
||||
|
||||
let g:coc_global_extensions = ['coc-json', 'coc-git', 'coc-tsserver', 'coc-pyright', 'coc-solidity']
|
||||
|
|
|
|||
|
|
@ -27,19 +27,35 @@ vnoremap <leader>P "+P
|
|||
|
||||
|
||||
" tab navigation mappings
|
||||
map tt :tabnew<CR>
|
||||
map <S-k> :tabn<CR>
|
||||
imap <S-k> <ESC>:tabn<CR>
|
||||
map <S-j> :tabp<CR>
|
||||
imap <S-j> <ESC>:tabp<CR>
|
||||
map <M-k> :tabn<CR>
|
||||
imap <M-k> <ESC>:tabn<CR>
|
||||
map <M-j> :tabp<CR>
|
||||
imap <M-j> <ESC>:tabp<CR>
|
||||
|
||||
" New tab
|
||||
map <C-t> :tabnew<CR>
|
||||
imap <C-t> <ESC>:tabnew<CR>
|
||||
|
||||
" Close tab
|
||||
map <C-q> :tabclose<CR>
|
||||
imap <C-q> :tabclose<CR>
|
||||
|
||||
" Move Right
|
||||
map <C-l> :tabn<CR>
|
||||
imap <C-l> <ESC>:tabn<CR>
|
||||
map <C-j> :tabn<CR>
|
||||
imap <C-j> <ESC>:tabn<CR>
|
||||
|
||||
" Move Left
|
||||
map <C-h> :tabp<CR>
|
||||
imap <C-h> <ESC>:tabp<CR>
|
||||
map <C-k> :tabp<CR>
|
||||
imap <C-k> <ESC>:tabp<CR>
|
||||
|
||||
" clear search results
|
||||
nnoremap <silent> // :noh<CR>
|
||||
|
||||
" FZF Searches
|
||||
nnoremap <C-p> :History<CR>
|
||||
nnoremap <C-b> :Buffers<CR>
|
||||
nnoremap <C-g> :GGrep<CR>
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ function! s:check_back_space() abort
|
|||
endfunction
|
||||
inoremap <silent><expr> <TAB>
|
||||
\ pumvisible() ? "\<C-n>" :
|
||||
\ <SID>check_back_space() ? "\<TAB>" :
|
||||
"\ <SID>check_back_space() ? "\<TAB>" :
|
||||
\ coc#refresh()
|
||||
inoremap <expr><S-TAB> pumvisible() ? "\<C-p>" : "\<C-h>"
|
||||
|
||||
|
|
@ -57,7 +57,7 @@ nmap <silent> gi <Plug>(coc-implementation)
|
|||
nmap <silent> gr <Plug>(coc-references)
|
||||
|
||||
" Use K to show documentation in preview window
|
||||
"nnoremap <silent> K :call <SID>show_documentation()<CR>
|
||||
nnoremap <silent> K :call <SID>show_documentation()<CR>
|
||||
|
||||
function! s:show_documentation()
|
||||
if (index(['vim','help'], &filetype) >= 0)
|
||||
|
|
@ -137,7 +137,7 @@ function! StatusDiagnostic() abort
|
|||
endfunction
|
||||
|
||||
" Disable node version warning
|
||||
let g:coc_disable_startup_warning = 1
|
||||
let g:coc_disable_startup_warning = 0
|
||||
|
||||
" Vim script coc extension
|
||||
let g:markdown_fenced_languages = [
|
||||
|
|
|
|||
|
|
@ -1,2 +1,4 @@
|
|||
let g:NERDCustomDelimiters = {'javascript': { 'left': '//', 'right': '', 'leftAlt': '{/* ', 'rightAlt': ' */}' }, 'vyper': { 'left': '# ', 'right': '' }}
|
||||
Plug 'preservim/nerdcommenter'
|
||||
" quick commenter
|
||||
"
|
||||
|
|
|
|||
|
|
@ -154,14 +154,37 @@ Plug 'neomake/neomake'
|
|||
|
||||
" Nice icons: Need to install patched font for this to work
|
||||
Plug 'ryanoasis/vim-devicons'
|
||||
" This is solves a bug in devicons that appears when sourcing vimrc
|
||||
if exists("g:loaded_webdevicons")
|
||||
call webdevicons#refresh()
|
||||
endif
|
||||
|
||||
" Devicon Configurations
|
||||
" loading the plugin
|
||||
let g:webdevicons_enable = 1
|
||||
|
||||
" This is solves a bug in devicons that appears when sourcing vimrc
|
||||
if !exists('g:syntax_on')
|
||||
syntax enable
|
||||
endif
|
||||
if exists("g:loaded_webdevicons")
|
||||
call webdevicons#refresh()
|
||||
endif
|
||||
|
||||
let g:webdevicons_enable_nerdtree = 1
|
||||
|
||||
" let g:NERDTreeHighlightFolders = 1
|
||||
let g:NERDTreeHighlightFoldersFullName = 1
|
||||
let g:WebDevIconsUnicodeDecorateFolderNodes = 1 " enable folder glyph flag
|
||||
let g:DevIconsEnableFoldersOpenClose = 1
|
||||
let g:DevIconsEnableFolderExtensionPatternMatching = 1
|
||||
let g:webdevicons_conceal_nerdtree_brackets = 1
|
||||
|
||||
" Basically disable nerdtree markers
|
||||
let g:NERDTreeDirArrowExpandable = ' '
|
||||
let g:NERDTreeDirArrowCollapsible = ' '
|
||||
|
||||
let g:WebDevIconsUnicodeDecorateFolderNodesDefaultSymbol = ' '
|
||||
let g:DevIconsDefaultFolderOpenSymbol = ' '
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
" add or override individual additional filetypes
|
||||
|
|
@ -179,16 +202,25 @@ Plug 'junegunn/goyo.vim'
|
|||
" Goyo mappings
|
||||
nmap <C-g> :Goyo<CR>
|
||||
|
||||
|
||||
" Slimux
|
||||
Plug 'esamattis/slimux'
|
||||
Plug 'lotabout/slimux'
|
||||
map <M-s> :SlimuxREPLSendLine<CR>j
|
||||
vmap <M-s> :SlimuxREPLSendSelection<CR>
|
||||
|
||||
Plug 'pangloss/vim-javascript'
|
||||
|
||||
Plug 'iamcco/markdown-preview.nvim', { 'do': 'cd app && yarn install' }
|
||||
"Plug 'iamcco/markdown-preview.nvim', { 'do': 'cd app && yarn install' }
|
||||
|
||||
Plug 'neoclide/coc.nvim', {'branch': 'release'}
|
||||
"Plug 'neoclide/coc.nvim', {'branch': 'release'}
|
||||
Plug 'neoclide/coc.nvim', {'do': { -> coc#util#install()}}
|
||||
Plug 'neoclide/coc-snippets', {'do': 'yarn install --frozen-lockfile'}
|
||||
Plug 'neoclide/coc-tsserver', {'do': 'yarn install --frozen-lockfile'}
|
||||
Plug 'neoclide/coc-prettier', {'do': 'yarn install --frozen-lockfile'}
|
||||
Plug 'neoclide/coc-eslint', {'do': 'yarn install --frozen-lockfile'}
|
||||
Plug 'neoclide/coc-css', {'do': 'yarn install --frozen-lockfile'}
|
||||
Plug 'neoclide/coc-lists', {'do': 'yarn install --frozen-lockfile'} " mru and stuff
|
||||
Plug 'neoclide/coc-highlight', {'do': 'yarn install --frozen-lockfile'} " color highlighting
|
||||
|
||||
Plug 'neoclide/jsonc.vim'
|
||||
|
||||
|
|
@ -198,6 +230,14 @@ Plug 'vimwiki/vimwiki'
|
|||
|
||||
Plug 'bfredl/nvim-ipy'
|
||||
|
||||
Plug 'vyperlang/vim-vyper'
|
||||
|
||||
Plug 'jmcantrell/vim-virtualenv'
|
||||
|
||||
Plug 'mkitt/tabline.vim'
|
||||
|
||||
Plug 'prisma/vim-prisma'
|
||||
|
||||
" Tell vim-plug we finished declaring plugins, so it can load them
|
||||
call plug#end()
|
||||
|
||||
|
|
|
|||
|
|
@ -7,15 +7,16 @@ set tags=tags
|
|||
" ------------------------------------------------------------------------------
|
||||
" These are inherited from MattCoding4Days
|
||||
"" Make vim scroll faster
|
||||
set ttyfast
|
||||
set ttyfast " Removed in Nvim "
|
||||
set mouse=a
|
||||
set lazyredraw
|
||||
set nu
|
||||
set nowrap
|
||||
set relativenumber
|
||||
set encoding=UTF-8
|
||||
" set tabline to not display full path
|
||||
set guitablabel=%t
|
||||
" set tabline to (not) display full path
|
||||
set guitablabel=%F
|
||||
set showtabline=2
|
||||
|
||||
" tabs and spaces handling
|
||||
set expandtab
|
||||
|
|
|
|||
|
|
@ -19,5 +19,3 @@ if (&term =~? 'mlterm\|xterm\|xterm-256\|screen-256') || has('nvim')
|
|||
else
|
||||
colorscheme jellybeans
|
||||
endif
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue