aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTeddy Wing2015-08-13 11:50:32 -0400
committerTeddy Wing2015-08-13 11:50:32 -0400
commitdd151e54fac910363a0bbe423d2057b8c68cf940 (patch)
tree43171afde176083763ab0c8695d08c8d424820cb
parent34cc2287375ea4824d27a57e007fecde49610e65 (diff)
downloaddotvim-dd151e54fac910363a0bbe423d2057b8c68cf940.tar.bz2
ftplugin/python.vim: Add mapping to flake8
Add a mapping to flake8 the current file for PEP8 syntax violations so I don't have to type out the path of a file that I already have open in order to check it against flake8.
-rw-r--r--ftplugin/python.vim4
1 files changed, 4 insertions, 0 deletions
diff --git a/ftplugin/python.vim b/ftplugin/python.vim
index 7ebcbae..434ae8e 100644
--- a/ftplugin/python.vim
+++ b/ftplugin/python.vim
@@ -19,3 +19,7 @@ nnoremap <buffer> O O
" Quickly add a debug line
nnoremap <buffer> <leader>gdo oimport ipdb; ipdb.set_trace()<Esc>_
nnoremap <buffer> <leader>gdO Oimport ipdb; ipdb.set_trace()<Esc>_
+
+
+" Flake8 validation
+nnoremap <buffer> <leader>gs :!flake8 %<cr>