1
0
forked from aniani/vim

567 Commits

Author SHA1 Message Date
Aliaksei Budavei
36e667ab83
runtime(java): Support "g:ftplugin_java_source_path" with archived files
Also, document for "g:ftplugin_java_source_path" its current
modification of the local value of the 'path' option.

closes: #14570

Signed-off-by: Aliaksei Budavei <0x000c70@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-18 23:08:59 +02:00
Wu, Zhenyu
f9f5424d3e
patch 9.1.0326: filetype: some requirements files are not recognized
Problem:  filetype: some requirements files are not recognized
Solution: Detect '*-requirements.txt', 'constraints.txt',
          'requirements.in', 'requirements/*.txt' and 'requires/*.txt'
          as requirements filetype, include pip compiler, include
          requirements filetype and syntax plugin
          (Wu, Zhenyu, @raimon49)

closes: #14379

Co-authored-by: raimon <raimon49@hotmail.com>
Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-14 20:43:27 +02:00
wzy
8a31de6dd2
compiler(rime_deployer): include new compiler, use it for '*.custom.yaml' files (#14460)
Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-14 20:28:29 +02:00
Shane-XB-Qian
e92ed1b45c
runtime(vim): don't set compiler, update a comment for vimdoc compiler (#14532)
Signed-off-by: shane.xb.qian <shane.qian@foxmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-14 20:20:01 +02:00
Aliaksei Budavei
4052474a1b
runtime(java): Recognise non-ASCII identifiers (#14543)
* runtime(java): Recognise non-ASCII identifiers

Also:

- Remove the already commented out and less general in its
  definition javaFuncDef alternative.

- Stop recognising some bespoke {p,trace} debugging API.

Non-ASCII identifiers have been supported from the outset
of the Java language.

> An _identifier_ is an unlimited-length sequence of _Java
> letters_ and _Java digits_, the first of which must be a
> Java letter.  An identifier cannot have the same spelling
> (Unicode character sequence) as a keyword . . . Boolean
> literal . . . or the null literal . . .
> . . . . . . . .
> Letters and digits may be drawn from the entire Unicode
> character set . . .
> . . . . . . . .
> A Java letter is a character for which the method
> Character.isJavaLetter . . . returns true.  A Java
> letter-or-digit is a character for which the method
> Character.isJavaLetterOrDigit . . . returns true.
> . . . . . . . .
> The Java letters include . . . for historical reasons, the
> ASCII underscore (_) . . . and dollar sign ($) . . .

(Separate syntax tests will be written when particular parts
now touched will have been further improved.)

Reference:
https://javaalmanac.io/jdk/1.0/langspec.pdf [§3.8]

* Take on the maintenance of Java filetype and syntax files


Signed-off-by: Aliaksei Budavei <0x000c70@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-14 18:57:00 +02:00
wzy
0549c503ba
runtime(dts): include ftplugin support (#14522)
Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-12 18:36:57 +02:00
Christian Brabandt
159dc0fcf9
runtime(kconfig): add include to ftplugin (#14524)
related: #14521

Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-12 18:33:48 +02:00
Wu, Zhenyu
fcbefe74f1
runtime(compiler): add vimdoc
closes: #14459

https://github.com/google/vimdoc generates vim help files from vimscript files

Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-11 21:25:39 +02:00
Wu, Zhenyu
dbca7d8045
ftplugin(asm): add Matchit support
closes: #14461

Refer https://github.com/vim/vim/blob/master/runtime/ftplugin/masm.vim#L18-L29

Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-10 22:58:03 +02:00
Wu, Zhenyu
1492fe6903
patch 9.1.0304: filetype: cgdb config file is not recognized
Problem:  filetype: cgdb config file is not recognized
Solution: Detect cgdbrc files as cgdbrc filetype
          (Wu, Zhenyu)

closes: #14458

Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-10 22:52:40 +02:00
Wu, Zhenyu
556c621659
ftplugin(gdb): add matchit support
closes: #14462

Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-10 22:44:21 +02:00
Bruno BELANYI
6be7ef5bc7
patch 9.1.0302: filetype: blueprint files are not recognized
Problem:  filetype: blueprint files are not recognized
Solution: Detect '*.bp' files as blueprint files, add
          a minimal filetype plugin (Bruno Belanyi)

See: https://source.android.com/docs/setup/build

closes: #14488

Signed-off-by: Bruno BELANYI <bruno@belanyi.fr>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-10 22:28:28 +02:00
dkearns
04e5363b82
runtime(vim): Improve Vim9 and legacy-script comment highlighting (#13104)
This is a first-pass attempt to limit matching of Vim9 and legacy-script
comments to the appropriate syntactic contexts.

Vim9-script comments are highlighted at top level in a Vim9-script file,
in all :def functions, and in all :autocmd and :commmand command blocks.
Legacy-script comments are highlighted at top level in a legacy script
file, in all :func functions and in the Vim9-script preamble before the
:vim9script marker command.

Fixes #13047, #11307 and #9587.

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-10 22:18:37 +02:00
nat-418
196b6678c5
patch 9.1.0279: filetype: roc files are not recognized
Problem:  filetype: roc files are not recognized
Solution: Detect '*.roc' files as roc filetype,
          add a basic filetype plugin (nat-418)

closes: #14416

Signed-off-by: nat-418 <93013864+nat-418@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-08 22:23:22 +02:00
Wu, Zhenyu
72d81a66ed
patch 9.1.0278: filetype: zathurarc files not recognized
Problem:  filetype: zathurarc files not recognized
Solution: Detect '.zathurarc' files as zathurarc filetype,
          add zathurarc filetype (Wu, Zhenyu)

closes: #14380

Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-08 22:19:06 +02:00
James McCoy
2708c0b585
runtime(deb822sources): Add minimal ftplugin (#14240)
Set comment related options and avoid automatic line wrapping.

Signed-off-by: James McCoy <jamessan@jamessan.com>
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-03-20 19:55:05 +01:00
MyyPo
ef21bcaab1
runtime(rust): Respect no_plugin_maps and no_rust_maps globals (#14221)
Signed-off-by: myypo <nikirsmcgl@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-03-18 19:38:09 +01:00
dkearns
e93afc2e61
runtime(r,rhelp,rmd,rnoweb,rrst): Update ftplugin, browsefilter labels (#14126)
Use the standard format for browsefilter labels:
  "File Description (*.ext1, *.ext2, *.ext3)"

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-03-02 19:27:47 +01:00
dkearns
e84d2d4432
runtime(sh): Update ftplugin, fix #14101 (#14102)
Add the 'b' flag to 'comments', so that the shebang line is not detected as comment.

Fixes #14101.

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-02-27 20:00:32 +01:00
Christian Brabandt
f9ca139e3a
runtime(misc): announce adoption of various runtime files
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-02-19 20:46:49 +01:00
Luca Saccarola
1da0e85816
runtime(asciidoc): include basic ftplugin
closes: #13873

Signed-off-by: Luca Saccarola <github.e41mv@aleeas.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-02-14 22:26:43 +01:00
dkearns
21ce159e05
runtime(vim): Update syntax and ftplugin files (#13924)
Improve matching of line-continuations and interspersed comments.

These are now also matched in multiline syntax command patterns,
dictionary literals, and parenthesised expressions and argument lists.

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-01-28 18:54:08 +01:00
Melker Ulander
772f8f5425
runtime(hurl): add hurl filetype plugin(#13921)
Signed-off-by: Melker Ulander <melker.ulander@pm.me>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-01-27 11:26:14 +01:00
Maxim Kim
211211052d
runtime(odin): include ftplugin, syntax and indent script (#13867)
Note for Neovim Contributors: this is bundled as Vim9 Script. If you want to use this on Neovim, you need to convert the Vim9 scripts to Vim Script or Lua or leave it out.

Signed-off-by: Maxim Kim <habamax@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-01-16 17:33:51 +01:00
Doug Kearns
93197fde0f
runtime(ftplugin): Use "*" browsefilter pattern to match "All Files"
Problem:  The "*.*" browsefilter pattern only matches all files on
	  Windows (Daryl Lee)
Solution: Use "*" to filter on all platforms but keep "*.*" as the label
	  text on Windows. (Fixes #12685, Doug Kearns)

The *.* browsefilter pattern used to match "All Files" on Windows is a
legacy of the DOS 8.3 filename wildcard matching algorithm.  For reasons
of backward compatibility this still works on Windows to match all
files, even those without an extension.

However, this pattern only matches filenames containing a dot on other
platforms.  This often makes files without an extension difficult to
access from the file dialog, e.g., "Makefile"

On Windows it is still standard practice to use "*.*" for the filter
label so ftplugins should use "All Files (*.*)" on Windows and "All
Files (*)" on other platforms.  This matches Vim's default browsefilter
values.

This commit also normalises the browsefilter conditional test to check
for the Win32 and GTK GUI features and an unset b:browsefilter.

closes: #12759

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-01-14 21:02:54 +01:00
Doug Kearns
68a8947069
patch 9.1.0013: Modula2 filetype support lacking
Problem:  Modula2 filetype support lacking
Solution: Improve the Modula-2 runtime support, add additional modula2
          dialects, add compiler plugin, update syntax highlighting,
          include syntax tests, update Makefiles (Doug Kearns)

closes: #6796
closes: #8115

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Benjamin Kowarsch <trijezdci@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-01-05 17:59:04 +01:00
dkearns
d08059ab48
runtime(ruby): Update ftplugin and omni-complete (#13805)
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-01-01 18:58:57 +01:00
Tim Pope
244f01658f runtime(markdown): Fix folding of code blocks 2023-12-28 23:17:54 +01:00
Tim Pope
a907c91992 runtime(sass): Provide sass_recommended_style option 2023-12-28 23:17:54 +01:00
Tim Pope
fda02d03c0 runtime(gitcommit): Updates to ftplugin and syntax 2023-12-28 23:17:54 +01:00
Tim Pope
48ddc6a6f8 runtime(git): Add small ftplugin 2023-12-28 23:17:54 +01:00
Christian Brabandt
d1cea03646
runtime(elixir): missing undo_ftplugin for indentkeys
fixup after #13771

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-12-27 19:30:41 +01:00
George Guimarães
7e27411007
runtime(elixir): fix indentation (#13771)
Signed-off-by: George Guimarães <george.guimaraes@gmail.com>
Signed-off-by: Mitchell Hanberg <mitch@mitchellhanberg.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-12-27 19:06:05 +01:00
Lifepillar
0bca4a0018
runtime(context): update ConTeXt keywords and other minor fixes (#13778)
Update to the ConTeXt runtime files. Changes:

1. shared syntax files updated with `mtxrun --script interface --vim`
   using the latest ConTeXt LMTX.

2. fixed reference to `make` tag in the help file.

3. added `keepend` to mitigate issues with embedded Lua syntax (see
   below).

4. the latest revision date of each ConTeXt runtime file has been
   updated to the date of this commit.

The issue about embedded Lua was reported by a user:

>Take the following valid ConTeXt file:

>   \starttext
>   \ctxlua{context("Text generated from Lua.")}
>   \ctxlua{context("Another text generated from Lua.")}
>   \stoptext

>On my Vim installation (including when I start Vim with `--clean`), the
>closing bracket and curly braces on line 2 are highlighted red and the
>syntax highlighting after that is off.

>I was trying to dig a little bit into what was going on, using the
>`synID()` and `synIDattr()` functions. It appears that the closing
>bracket on line 2 is matched as a `luaParentError` instead of the end
>of the `luaParen` region. Therefore, the `luaParen` region continues
>all the way to the end of the file. The closing curly brace on line
>2 is matched as a `luaError`, the 2nd `\ctxlua` on line 3 as
>`luaParen`, etc.

>This issue doesn't occur in a plain Lua file, where the closing bracket
>is correctly matched as the end of the `luaParen` region. So it seems
>that something goes wrong when the Lua syntax file is included in the
>ConTeXt one.

By adding `keepend`, the right parenthesis for some reason is still
highlighted as a `luaParenError`, but at least the right curly brace
should correctly end the Lua block.

From what I've seen, I think it is very difficult to embed Lua syntax
properly without help from the Lua syntax file (that is, without
patching it). It has global rules such as:

   syn match  luaParenError ")"
   syn match  luaError "}"

which make it difficult, if not impossible, to contain Lua syntax
without `keepend` (and its limitations).


Signed-off-by: Lifepillar <lifepillar@lifepillar.me>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-12-27 18:49:50 +01:00
Ajit-Thakkar
ea9964a36f
Runtime(fortran): updates to indent, syntax and ftplugin (#13752)
* runtime update fortran.vim

Add folding for newer features of Fortran

* Runtime Update fortran.vim

Add indent support for newer features of Fortran

* Runtime Update fortran.vim

Add newer features of Fortran to matchit patterns

Signed-off-by: Ajit-Thakkar <142174202+Ajit-Thakkar@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-12-23 11:31:38 +01:00
Csaba Hoch
18ab6c3392
runtime(erlang): add support for matchit plugin (#13713)
This commit updates the Erlang runtime files to be in sync with the
`vim-erlang-runtime` repository. In particular, it adds the following
commit (with some cleanup and simplification afterwards):
6ea8b85bc9

Signed-off-by: Csaba Hoch <csaba.hoch@gmail.com>
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-12-21 17:16:28 +01:00
Paulo Moura
0f61943eb7
runtime(logtalk): Update Logtalk runtime files for the latest language spec (#13697)
Signed-off-by: Paulo Moura <pmoura@logtalk.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-12-16 14:27:09 +01:00
Karl Yngve Lervåg
5a68cdf149
runtime(sbt): do not set b:did_ftplugin before sourcing scala ftplugin(#13657)
The `b:did_ftplugin` guard was set and prevented us from actually sourcing `ftplugin/scala.vim`. Since the latter script also sets the guard properly, we can simply remove the guard here.

Signed-off-by: =?UTF-8?q?Karl=20Yngve=20Lerv=C3=A5g?= <karl.yngve+git@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-12-11 17:17:20 +01:00
Ajit-Thakkar
6863084d3b
runtime(fortran): update syntax and ftplugins
closes: #13629

Signed-off-by: Ajit-Thakkar <142174202+Ajit-Thakkar@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-12-05 23:08:59 +01:00
Julien Marrec
2e31065a65
patch 9.0.2128: runtime(swig): add syntax and filetype plugins
Add syntax and filetype plugins for SWIG (Simplified Wrapper Interface
Generator) description files.

The default syntax for .i files highlights comments in a reverse
color scheme which doesn't look well.  This syntax builds
on vim's c++ syntax by adding highlighting for common swig
directives and user defined directives.  For an alternative
syntax, see vimscript #1247 (which I found after writing this).

closes: #13562

Co-authored-by: Matěj Cepl <mcepl@cepl.eu>
Co-authored-by: Julien Marrec <julien.marrec@gmail.com>
Signed-off-by: Julien Marrec <julien.marrec@gmail.com>
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-11-25 15:30:46 +01:00
rhysd
bc8f79d36a
patch 9.0.2104: wast filetype should be replaced by wat filetype
Problem:  wast filetype should be replaced by wat filetype
Solution: start using the official wat filetype name

runtime: rename `wast` filetype to `wat` (Wasm text format)

The problem is the name of the current filetype wast. When the plugin
was initially created, the file extension for Wasm text format was not
fixed and .wast was more popular.

However, recently .wat became the official file extension for
WebAssembly text (WAT) format and .wast is now a file extension for the
unofficial WAST format, which is a superset of .wat for the convenience
to describe the Wasm specification conformance tests.

https://webassembly.js.org/docs/contrib-wat-vs-wast.html

However for now, let's keep using the `wat` filetype even for the .wast
extension, so that we at least do not lose the filetype settings and
syntax highlighting. This can be adjusted later, if it turns out to have
a separate need for.

closes: #13533

Signed-off-by: rhysd <lin90162@yahoo.co.jp>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-11-14 16:46:07 +01:00
dkearns
2c133f6c1a
runtime(lynx): Update for Lynx 2.8.9 (#13510)
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-11-11 19:06:56 +01:00
ObserverOfTime
4f9074b96c
patch 9.0.2098: No filetype support for xcompose files
Problem:  No filetype support for xcompose files
Solution: Add filetype detection

closes: #13508

Signed-off-by: ObserverOfTime <chronobserver@disroot.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-11-11 09:12:27 +01:00
dkearns
d56f15caf6
runtime(wget): Update for Wget2 2.1.0 (#13497)
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-11-08 20:53:20 +01:00
D. Ben Knoble
cd8a3eaf53
runtime(dist): centralize safe executable check and add vim library (#13413)
Follow up to 816fbcc26 (patch 9.0.1833: [security] runtime file fixes,
2023-08-31) and f7ac0ef50 (runtime: don't execute external commands when
loading ftplugins, 2023-09-06).

This puts the logic for safe executable checks in a single place, by introducing
a central vim library, so all filetypes benefit from consistency.

Notable changes:
- dist#vim because the (autoload) namespace for a new runtime support
  library. Supporting functions should get documentation. It might make
  life easier for NeoVim devs to make the documentation a new file
  rather than cram it into existing files, though we may want
  cross-references to it somewhere…
- The gzip and zip plugins need to be opted into by enabling execution
  of those programs (or the global plugin_exec). This needs
  documentation or discussion.
- This fixes a bug in the zig plugin: code setting s:tmp_cwd was removed
  in f7ac0ef50 (runtime: don't execute external commands when loading
  ftplugins, 2023-09-06), but the variable was still referenced. Since
  the new function takes care of that automatically, the variable is no
  longer needed.

Signed-off-by: D. Ben Knoble <ben.knoble+github@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-11-04 10:11:17 +01:00
James McCoy
7b7cda67a1
runtime(debian): update debian related runtime files (#13423)
* Update Debian runtime files

Add mantic as a supported Ubuntu release and move buster/kinetic to
unsupported.

Add syntax highlighting for deb822sources filetype.

Add debsources ftplugin to set relevant comment options.

Move common version information to shared/debversions.vim

Closes #11934

Co-authored-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Co-authored-by: James Addison <jay@jp-hosting.net>
Co-authored-by: Viktor Szépe <viktor@szepe.net>
Signed-off-by: James McCoy <jamessan@jamessan.com>

* Add myself as codeowner for Debian-related runtime files

Signed-off-by: James McCoy <jamessan@jamessan.com>

---------

Signed-off-by: James McCoy <jamessan@jamessan.com>
Co-authored-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Co-authored-by: James Addison <jay@jp-hosting.net>
Co-authored-by: Viktor Szépe <viktor@szepe.net>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-10-26 23:14:30 +02:00
Colin Kennedy
10407df7a9
patch 9.0.2071: objdump files not recognized
Problem:  objdump files not recognized
Solution: detect *.objdump files, add a filetype plugin

Added the objdump file/text format

closes: #13425

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Colin Kennedy <colinvfx@gmail.com>
2023-10-26 23:03:15 +02:00
dkearns
fea96c00e5
runtime(vim): Update ftplugin - comment motions (#13412)
Fix the pattern used by comment-motion mappings to match the start of a
block comment.

Block-comment start lines were being ignored if the previous line
contained a double-quote character anywhere in the line.  Line comments
should only be ignored if the previous line is a full-line comment and,
therefore, part of the current block comment.

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-10-23 18:16:44 +02:00
dkearns
d5dc58aeed
runtime(json5): Add new ftplugin (#13385)
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-10-19 20:00:12 +02:00
Gregory Anders
e08bfef88b
runtime(zig): Update Zig runtime files (#13388)
Update runtime files from upstream (https://github.com/zig/zig.vim) at
commit 54c216e5306a5c3878a60596aacb94dca8652ab9.

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-10-19 17:16:59 +02:00