Created
August 8, 2010 12:34
-
-
Save AndrewRadev/513976 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" Remap the 'Enter' key to process the command line before executing | |
cnoremap <cr> <c-r>=<SID>DoSomeChecks()<cr><cr> | |
function! s:DoSomeChecks() | |
let g:debug = getcmdline() | |
" and some more stuff... | |
" :doautocmd with a custom event maybe? | |
return '' | |
endfunction | |
" do something like :some-command | echo g:debug |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment