diff --git a/nvim/coc-languages/lisp.vim b/nvim/coc-languages/lisp.vim deleted file mode 100644 index 919a2eb..0000000 --- a/nvim/coc-languages/lisp.vim +++ /dev/null @@ -1,2 +0,0 @@ -call extend(g:dotfiles_coc_extensions, {'coc-cl': 1}) -call extend(g:dotfiles_coc_filetypes, {'lsp': 1}) diff --git a/nvim/init.vim b/nvim/init.vim index 6277f37..ec3f835 100644 --- a/nvim/init.vim +++ b/nvim/init.vim @@ -14,7 +14,7 @@ else endif " Arrow key fix kanged from {{{ - if g:HELP_MY_ARROW_KEYS_ARE_BROKEN + if exists("g:HELP_MY_ARROW_KEYS_ARE_BROKEN") " the following simply creates an ambiguous mapping so vim fully " processes the escape sequence for terminal keys, see 'ttimeout' for a " rough explanation, this just forces it to work diff --git a/nvim/plugin/keybinds.vim b/nvim/plugin/keybinds.vim index d970038..c8540af 100644 --- a/nvim/plugin/keybinds.vim +++ b/nvim/plugin/keybinds.vim @@ -1,5 +1,20 @@ nnoremap :NERDTreeToggle +" Completion {{{ + function! s:check_back_space() abort + let col = col('.') - 1 + return !col || getline('.')[col - 1] =~ '\s' + endfunction + + inoremap coc#pum#visible() ? coc#_select_confirm() : "\" + + inoremap + \ coc#pum#visible() ? coc#pum#next(1): + \ check_back_space() ? "\" : + \ coc#refresh() + inoremap coc#pum#visible() ? coc#pum#prev(1) : "\" +" }}} + " Copy to clipboard register and paste from clipboard register {{{ " Taken from https://unix.stackexchange.com/a/23437 nnoremap "+y