diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2023-08-02 19:46:52 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2023-08-02 19:46:52 +1200 |
commit | 3deb986d9743cc570160a391f02abfd233d5e9e4 (patch) | |
tree | 0b96defde98a09cd8cec624d7897fcf0bce14bef | |
parent | Add Vim filetype detection for Rust (diff) | |
download | dotfiles-3deb986d9743cc570160a391f02abfd233d5e9e4.tar.gz dotfiles-3deb986d9743cc570160a391f02abfd233d5e9e4.zip |
Handle unset b:undo_ftplugin in Python Vim
-rw-r--r-- | vim/after/ftplugin/python.vim | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/vim/after/ftplugin/python.vim b/vim/after/ftplugin/python.vim index cf7b00b7..2ca1ae89 100644 --- a/vim/after/ftplugin/python.vim +++ b/vim/after/ftplugin/python.vim @@ -1,3 +1,11 @@ +" The Python runtime files didn't define b:undo_ftplugin until Vim v8.1.1048; +" if it's not set yet, set it here (to something innoccuous) so that the +" appending :let commands in the rest of this file don't break. +" +if !exists('b:undo_ftplugin') + let b:undo_ftplugin = 'setlocal tabstop<' +endif + " Use pyflakes for syntax checking and autopep8 for tidying compiler pyflakes if executable('autopep8') |