diff options
author | Bram Moolenaar <Bram@vim.org> | 2020-10-11 13:57:40 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2020-10-11 13:57:40 +0200 |
commit | 4f4d51a942cc2c6b3e936ee0f93f00c2d000065c (patch) | |
tree | 68c8e3f28d26abf029d6d67747897b1bf43b885c /runtime/ftplugin | |
parent | c6ed254d9fda0ff54cdedce5597ff3e0d0218d18 (diff) | |
download | vim-git-4f4d51a942cc2c6b3e936ee0f93f00c2d000065c.tar.gz |
Update runtime files.
Diffstat (limited to 'runtime/ftplugin')
-rw-r--r-- | runtime/ftplugin/falcon.vim | 3 | ||||
-rw-r--r-- | runtime/ftplugin/fortran.vim | 12 | ||||
-rw-r--r-- | runtime/ftplugin/python.vim | 42 |
3 files changed, 21 insertions, 36 deletions
diff --git a/runtime/ftplugin/falcon.vim b/runtime/ftplugin/falcon.vim index 4fc135b4a..affca3848 100644 --- a/runtime/ftplugin/falcon.vim +++ b/runtime/ftplugin/falcon.vim @@ -3,6 +3,7 @@ " Author: Steven Oliver <oliver.steven@gmail.com> " Copyright: Copyright (c) 2009-2013 Steven Oliver " License: You may redistribute this under the same terms as Vim itself +" Last Update: 2020 Oct 10 " -------------------------------------------------------------------------- " Only do this when not done yet for this buffer @@ -14,7 +15,7 @@ let b:did_ftplugin = 1 let s:cpo_save = &cpo set cpo&vim -setlocal softtabstop=4 shiftwidth=4 fileencoding=utf-8 +setlocal softtabstop=4 shiftwidth=4 setlocal suffixesadd=.fal,.ftd " Matchit support diff --git a/runtime/ftplugin/fortran.vim b/runtime/ftplugin/fortran.vim index 385f1557d..b9ba3c472 100644 --- a/runtime/ftplugin/fortran.vim +++ b/runtime/ftplugin/fortran.vim @@ -1,13 +1,13 @@ " Vim settings file " Language: Fortran 2008 (and older: Fortran 2003, 95, 90, 77, 66) -" Version: 0.50 -" Last Change: 2020 Apr 20 -" Patched By: Eisuke Kawashima +" Version: (v52) 2020 October 07 " Maintainer: Ajit J. Thakkar <ajit@unb.ca>; <http://www2.unb.ca/~ajit/> " Usage: For instructions, do :help fortran-plugin from Vim " Credits: -" Useful suggestions were made by Stefano Zacchiroli, Hendrik Merx, Ben -" Fritz, and David Barnett. +" Version 0.1 was created in September 2000 by Ajit Thakkar. +" Since then, useful suggestions and contributions have been made, in order, by: +" Stefano Zacchiroli, Hendrik Merx, Ben Fritz, David Barnett, Eisuke Kawashima, +" and Doug Kearns. " Only do these settings when not done yet for this buffer if exists("b:did_ftplugin") @@ -119,7 +119,7 @@ if !exists("b:match_words") endif " File filters for :browse e -if has("gui_win32") && !exists("b:browsefilter") +if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter") let b:browsefilter = "Fortran Files (*.f;*.for;*.f77;*.f90;*.f95;*.f03;*.f08;*.fpp;*.ftn)\t*.f;*.for;*.f77;*.f90;*.f95;*.f03;*.f08;*.fpp;*.ftn\n" . \ "All Files (*.*)\t*.*\n" endif diff --git a/runtime/ftplugin/python.vim b/runtime/ftplugin/python.vim index 64c1a87a6..000ddf52a 100644 --- a/runtime/ftplugin/python.vim +++ b/runtime/ftplugin/python.vim @@ -3,7 +3,7 @@ " Maintainer: Tom Picton <tom@tompicton.co.uk> " Previous Maintainer: James Sully <sullyj3@gmail.com> " Previous Maintainer: Johannes Zellner <johannes@zellner.org> -" Last Change: Sun 17 Mar 2019 +" Last Change: Mon, 5 October 2020 " https://github.com/tpict/vim-ftplugin-python if exists("b:did_ftplugin") | finish | endif @@ -14,6 +14,7 @@ set cpo&vim setlocal cinkeys-=0# setlocal indentkeys-=0# setlocal include=^\\s*\\(from\\\|import\\) +setlocal define=^\\s*\\(def\\\|class\\) " For imports with leading .., append / and replace additional .s with ../ let b:grandparent_match = '^\(.\.\)\(\.*\)' @@ -38,7 +39,7 @@ setlocal comments=b:#,fb:- setlocal commentstring=#\ %s if has('python3') - setlocal omnifunc=python3complete#Complete + setlocal omnifunc=python3complete#Complete elseif has('python') setlocal omnifunc=pythoncomplete#Complete endif @@ -115,35 +116,18 @@ endif if !exists("g:python_recommended_style") || g:python_recommended_style != 0 " As suggested by PEP8. - setlocal expandtab shiftwidth=4 softtabstop=4 tabstop=8 + setlocal expandtab tabstop=4 softtabstop=4 shiftwidth=4 endif -" First time: try finding "pydoc". -if !exists('g:pydoc_executable') - if executable('pydoc') - let g:pydoc_executable = 1 - else - let g:pydoc_executable = 0 - endif -endif - -" Windows-specific pydoc setup -if has('win32') || has('win64') - if executable('python') - " available as Tools\scripts\pydoc.py - let g:pydoc_executable = 1 - else - let g:pydoc_executable = 0 - endif -endif - -" If "pydoc" was found use it for keywordprg. -if g:pydoc_executable - if has('win32') || has('win64') - setlocal keywordprg=python\ -m\ pydoc\ - else - setlocal keywordprg=pydoc - endif +" Use pydoc for keywordprg. +" Unix users preferentially get pydoc3, then pydoc2. +" Windows doesn't have a standalone pydoc executable in $PATH by default, nor +" does it have separate python2/3 executables, so Windows users just get +" whichever version corresponds to their installed Python version. +if executable('python3') + setlocal keywordprg=python3\ -m\ pydoc +elseif executable('python') + setlocal keywordprg=python\ -m\ pydoc endif " Script for filetype switching to undo the local stuff we may have changed |