Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
DanNixon committed Jan 15, 2024
1 parent 3225e9b commit 4e9f58c
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions modules/home-manager/terminal_environment/neovim/config.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
filetype off
" TODO: upstream this to ALE
function! Doot(buffer) abort
let l:project_root = ale#path#FindNearestDirectory(a:buffer, 'flake.nix')
Expand Down Expand Up @@ -39,17 +40,18 @@
function! s:check_back_space() abort
let col = col('.') - 1
return !col || getline('.')[col - 1] =~ '\s'
return !col || getline('.')[col - 1] =~ '\s'
endfunction
inoremap <silent><expr> <TAB>
\ pumvisible() ? "\<C-n>" :
\ <SID>check_back_space() ? "\<TAB>" :
inoremap <silent><expr> <S-TAB>
\ pumvisible() ? "\<C-p>" :
\ <SID>check_back_space() ? "\<S-TAB>" :
\ asyncomplete#force_refresh()
inoremap <expr><S-TAB> pumvisible() ? "\<C-p>" : "\<C-h>"
" Copilot config
let g:copilot_no_tab_map = v:true
inoremap <expr> <cr> pumvisible() ? asyncomplete#close_popup() : "\<cr>"
inoremap <silent><expr> j pumvisible() ? "\<C-n>" : "j"
inoremap <silent><expr> k pumvisible() ? "\<C-p>" : "k"
" Tagbar config
let g:tagbar_autofocus = 1
Expand Down

0 comments on commit 4e9f58c

Please sign in to comment.