aboutsummaryrefslogtreecommitdiff
path: root/stow/vim/.vim/ftplugin/python
diff options
context:
space:
mode:
Diffstat (limited to 'stow/vim/.vim/ftplugin/python')
-rw-r--r--stow/vim/.vim/ftplugin/python/python.vim2
-rw-r--r--stow/vim/.vim/ftplugin/python/snips/for2
-rw-r--r--stow/vim/.vim/ftplugin/python/snips/if2
-rw-r--r--stow/vim/.vim/ftplugin/python/snips/template6
4 files changed, 11 insertions, 1 deletions
diff --git a/stow/vim/.vim/ftplugin/python/python.vim b/stow/vim/.vim/ftplugin/python/python.vim
index 358f902..b868b10 100644
--- a/stow/vim/.vim/ftplugin/python/python.vim
+++ b/stow/vim/.vim/ftplugin/python/python.vim
@@ -32,3 +32,5 @@ let mapleader = ","
inoremap <buffer> <leader>temp <Esc>:-1r ~/.vim/ftplugin/python/snips/template<CR>Gdd?<+++><CR>cf>
inoremap <buffer> <leader>class <Esc>:-1r ~/.vim/ftplugin/python/snips/class<CR>Gdd?<+++><CR>cf>
+inoremap <buffer> <leader>if <Esc>:-1r ~/.vim/ftplugin/python/snips/if<CR>Gdd?<+++><CR>cf>
+inoremap <buffer> <leader>for <Esc>:-1r ~/.vim/ftplugin/python/snips/for<CR>Gdd?<+++><CR>cf>
diff --git a/stow/vim/.vim/ftplugin/python/snips/for b/stow/vim/.vim/ftplugin/python/snips/for
new file mode 100644
index 0000000..b50f669
--- /dev/null
+++ b/stow/vim/.vim/ftplugin/python/snips/for
@@ -0,0 +1,2 @@
+for i in range(<+++>):
+ <++>
diff --git a/stow/vim/.vim/ftplugin/python/snips/if b/stow/vim/.vim/ftplugin/python/snips/if
new file mode 100644
index 0000000..af3cef1
--- /dev/null
+++ b/stow/vim/.vim/ftplugin/python/snips/if
@@ -0,0 +1,2 @@
+if (<+++>):
+ <++>
diff --git a/stow/vim/.vim/ftplugin/python/snips/template b/stow/vim/.vim/ftplugin/python/snips/template
index d10fa4a..52ea16f 100644
--- a/stow/vim/.vim/ftplugin/python/snips/template
+++ b/stow/vim/.vim/ftplugin/python/snips/template
@@ -2,4 +2,8 @@
"""<+++>"""
-<++>
+def main():
+ <++>
+
+if __name__ == '__main__':
+ main()