From: martin f. krafft Date: Thu, 14 Oct 2021 01:20:48 +0000 (+1300) Subject: Updated settings for Python X-Git-Url: https://git.madduck.net/etc/vim.git/commitdiff_plain/9132d33abee90d0818186d54792a80431b20386f?ds=sidebyside;hp=2054dd2d4e8f2fc94f2d5c78c7dbeb5f6a28c440 Updated settings for Python --- diff --git a/.vim/UltiSnips/python.snippets b/.vim/UltiSnips/python.snippets new file mode 100644 index 0000000..ecb4e8e --- /dev/null +++ b/.vim/UltiSnips/python.snippets @@ -0,0 +1,10 @@ +snippet #! "My own Python hashbang" b +#!/usr/bin/python3 +# -*- coding: utf-8 -*- +# +# Copyright © ${1:2021} martin f. krafft <${2:m@rtin.kiwi}> +# Released under the ${3:MIT} Licence. +# + +$0 +endsnippet diff --git a/.vim/after/ftplugin/python.vim b/.vim/after/ftplugin/python.vim index ffd59cf..34edf01 100644 --- a/.vim/after/ftplugin/python.vim +++ b/.vim/after/ftplugin/python.vim @@ -1,2 +1,20 @@ +let python_highlight_all=1 + +let g:linelength = 79 + setlocal sw=4 setlocal sts=4 +let &l:textwidth=g:linelength +setlocal autoindent + +setlocal formatoptions+=bl + +nnoremap :Black +inoremap :Black +nnoremap :call flake8#Flake8() +inoremap :call flake8#Flake8() + +let g:flake8_quickfix_height=3 +let g:black_linelength = g:linelength + +imap t import ipdb; ipdb.set_trace() diff --git a/.vim/ftplugin/python.vim b/.vim/ftplugin/python.vim deleted file mode 100644 index ec33e0c..0000000 --- a/.vim/ftplugin/python.vim +++ /dev/null @@ -1 +0,0 @@ -imap trace import ipdb; ipdb.set_trace()