开发者

VimScript or VimL?

开发者 https://www.devze.com 2023-01-29 22:27 出处:网络
What is th开发者_开发知识库e correct name of the Vim scripting language? I see it being called VimScript, Vim script and even VimL.

What is th开发者_开发知识库e correct name of the Vim scripting language? I see it being called VimScript, Vim script and even VimL.

VimL is even listed on GitHub as the 10th most popular programming language! What is the history behind the VimL name? Why are the Git folks calling it VimL?


After grepping through official documentation, it seems that "Vim script" is the "most" official name since nowhere is "VimScript" mentioned in regular sentences. GetLatestVimScripts is often mentioned, but this is a script name where no underlines are allowed.

I'd guess VimL is just an abbreviation for Vim Language (Vim script). It was probably coined some time ago and became used at few places, but it's not official.


This explains all terms used:

Vim’s built-in scripting language, VimL. This language is also known as Vimscript. Depending on how you look at it, either VimL is an alternate name for Vimscript or Vimscript is an alternate name for VimL.

Actually, there’s no real official name for the language; the closest seems to be the two-word “Vim script.” To better follow English naming conventions, this is usually altered to “Vimscript,” or more rarely, “Vim Script”—but all of this can be confusing, since the files which store code in this language are themselves called “Vim scripts.”

The relatively new name “VimL” (“Vim Language”) has been gaining in popularity in rough correlation with the growth of the code-sharing site GitHub. Its use is a matter of preference, but I do find it more easily distinguishable from mentions of Vim scripts or of writing generic scripts using Vim (in search results, for instance).

Read more - https://pragprog.com/book/bkviml/the-viml-primer


:h usr_41.txt says Vim script language for the language, and Vim script(s) for ..., well, scripts.

The abbreviation VimL sounds more correct to me.


Notice, that most of the opinions here suggesting VimL come from personal preference, observations of community behavior or references from good but still unofficial books. The truth is, whether we like it or not, and even when grammatical incorrect, the official name should be the one picked and used by Vim's original author, Bram Moolenaar; and he seems to always use Vim script.

For e.g. look at it being referred to as "Vim script" in the readme for his Vim9 repo — https://github.com/brammool/vim9

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号