From afe37052896997ad061369227d21feaea771ff10 Mon Sep 17 00:00:00 2001 From: Andrew Miner Date: Mon, 21 Sep 2026 08:44:03 -0600 Subject: [PATCH] Tidy up keymappings in vimrc --- home/.vimrc | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/home/.vimrc b/home/.vimrc index b75f017..7f7ca8a 100644 --- a/home/.vimrc +++ b/home/.vimrc @@ -119,12 +119,12 @@ endif let g:vim_json_syntax_conceal = 0 " godlygeek/tabular -nmap == :'a,.Tab /=/ -nmap =: :'a,.Tab /:/ -nmap =or :'a,.Tab /or/ -nmap =, :'a,.Tab /,/ -nmap =as :'a,.Tab /as/ -nmap =import :'a,.Tab /import/ +nnoremap == :'a,.Tab /=/ +nnoremap =: :'a,.Tab /:/ +nnoremap =or :'a,.Tab /or/ +nnoremap =, :'a,.Tab /,/ +nnoremap =as :'a,.Tab /as/ +nnoremap =import :'a,.Tab /import/ " nathanaelkane/vim-indent-guides let g:indent_guides_enable_on_vim_startup = 0 @@ -233,6 +233,7 @@ function! StartDailyReview() let todayLog = fnameescape($'log/{today}-daily.md') let yesterdayLog = fnameescape($'log/{yesterday}-daily.md') + NERDTreeClose execute $'edit {yesterdayLog}' vsplit set nowrap @@ -273,12 +274,11 @@ nnoremap :NERDTreeToggle \| wincmd p \| vertical resize 111 \| wincmd p :NERDTreeFind nnoremap :'a,.!sort -fg nnoremap :IndentGuidesToggle -nnoremap :call InsertDivider() inoremap :call InsertDivider() nnoremap :set hlsearch! nnoremap :cp +nnoremap :cwindow nnoremap :cn -nnoremap :copen nnoremap :call StartDailyReview() nnoremap c :ALEGoToTypeDefinition @@ -291,7 +291,7 @@ nnoremap r :ALEFindReferences nnoremap x :ALEToggle nnoremap w :w -nnoremap ' :BufExplorer +nnoremap ' :BufExplorer nnoremap j gj nnoremap k gk @@ -306,7 +306,8 @@ silent! source .vimrc.local " project specific .vimrc autocmd BufRead COMMIT_EDITMSG set textwidth=70 colorcolumn=70 autocmd BufRead Makefile setlocal noexpandtab autocmd BufRead *.scss setlocal shiftwidth=4 -autocmd BufNewFile,BufRead *.md Wrapwidth 100 | setlocal wrap textwidth=0 | setlocal spell +autocmd BufNewFile,BufRead *.md Wrapwidth 100 | setlocal textwidth=0 spell wrap +autocmd WinResized *.md Wrapwidth 100 autocmd FileType * setlocal formatoptions-=c formatoptions-=r formatoptions-=o " Startup Commands #################################################################################