Compare commits

...

2 Commits

Author SHA1 Message Date
Rob Watson 214ed43005 feat(nvim): add mapping
continuous-integration/drone/push Build is passing Details
2023-11-13 08:52:33 +01:00
Rob Watson a30fefbe36 chore(nvim): strip whitespace in bash 2023-11-13 08:52:01 +01:00
1 changed files with 2 additions and 1 deletions

3
nvimrc
View File

@ -105,7 +105,7 @@ augroup vimrc
" https://github.com/fatih/vim-go/issues/1757#issuecomment-565130503
autocmd FileType qf if (getwininfo(win_getid())[0].loclist != 1) | wincmd J | endif
" Remove trailing whitespace pre-save:
autocmd FileType go,ruby,markdown,rust,python,markdown,lua,sql autocmd BufWritePre <buffer> silent! %s/\s\+$//e
autocmd FileType go,ruby,markdown,rust,python,markdown,lua,sql,bash autocmd BufWritePre <buffer> silent! %s/\s\+$//e
augroup end
" Don't remember the current directory for a given file:
@ -184,6 +184,7 @@ endfunction
nnoremap <leader>as :Git<cr>
nnoremap <leader>ab :Git blame<cr>
nnoremap <leader>ac :Commits<cr>
nnoremap <leader>af gg0jVG:s/^pick/fixup/<cr> \| :redraw!<cr>:wq
nnoremap <leader>aY :call CopyGitURLToLineOrRange()<cr>
vnoremap <leader>aY :call CopyGitURLToLineOrRange()<cr>
nnoremap <leader>ao :call OpenGitURLToLineOrRange()<cr>