From dba1cc02dab57b5e5914738b86f340afc1be2308 Mon Sep 17 00:00:00 2001 From: Julio Biason Date: Wed, 23 Jul 2014 09:18:49 -0300 Subject: [PATCH] changed from snipmate to UltiSnips --- UltiSnips/python.snippets | 19 +++++++++++++++++++ configs/vimrc | 8 +++++++- 2 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 UltiSnips/python.snippets diff --git a/UltiSnips/python.snippets b/UltiSnips/python.snippets new file mode 100644 index 0000000..a5b0bef --- /dev/null +++ b/UltiSnips/python.snippets @@ -0,0 +1,19 @@ +snippet #py "Set the python environment." +#!/usr/bin/env python +#-*- encoding: utf-8 + +"""${1:Module documentation}""" +$0 +endsnippet + +snippet class "Starting a Python class" +class ${1:ClassName}(${2:extends}): + + """${3:Class documentation}""" + + $0 +endsnippet + +snippet lint "Start a lint-disable comment" +# pylint:disable=${0:lint code} +endsnippet diff --git a/configs/vimrc b/configs/vimrc index 2cc1875..8ef35e3 100644 --- a/configs/vimrc +++ b/configs/vimrc @@ -100,7 +100,8 @@ Plugin 'davidhalter/jedi-vim' Plugin 'pangloss/vim-javascript' " snippets -Plugin 'msanders/snipmate.vim' +" Plugin 'msanders/snipmate.vim' +Plugin 'SirVer/ultisnips' " fuzzy file open Plugin 'kien/ctrlp.vim' @@ -292,3 +293,8 @@ au FileType pinpoint setlocal colorcolumn=79 textwidth=78 " this disables the documentation/preview split autocmd FileType python setlocal completeopt-=preview let g:jedi#show_call_signatures = "0" + +" ---------------------------------------------------------------------- +" UltiSnips +" ---------------------------------------------------------------------- +let g:UltiSnipsEditSplit = "horizontal"