From 5b5d9d0cecf3be595737b40ec5dba63b690f53c8 Mon Sep 17 00:00:00 2001 From: Teddy Wing Date: Tue, 19 Sep 2017 05:18:52 +0200 Subject: vimrc: Add mk mapping to save Vim session I had previously defined this command as 'af83'-project-specific. Now I've become used to it and want to use it everywhere, so promote it to a global mapping. --- projects/af83.vim | 3 --- vimrc | 4 ++++ 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/projects/af83.vim b/projects/af83.vim index 2617c2e..75544a7 100644 --- a/projects/af83.vim +++ b/projects/af83.vim @@ -5,9 +5,6 @@ augroup af83 autocmd BufRead,BufEnter $VIM_PROJECT_PATH_AF83/* \ let g:pick_command = "ag -l -a -p './.agignore' -g ''" - autocmd BufRead,BufEnter $VIM_PROJECT_PATH_AF83/* - \ nnoremap mk :mksession! vimsession - autocmd BufRead,BufEnter $VIM_PROJECT_PATH_AF83/* \ let g:rspec_command = "!bundle exec spring rspec {spec}" augroup END diff --git a/vimrc b/vimrc index b511318..d61defe 100644 --- a/vimrc +++ b/vimrc @@ -378,6 +378,7 @@ " 2017.09.19: " * Set 'backspace=2' because that doesn't get set by default on some " Vims. +" * Add mk to save a Vim session file. " @@ -739,6 +740,9 @@ nnoremap gp :!git log -p -- % " Copy the current file path into the OS X pasteboard nnoremap cf :call system('pbcopy', expand('%')) +" Save the current session to a file +nnoremap mk :mksession! vimsession + " Project Settings -- cgit v1.2.3