Update runtime files
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
*usr_41.txt* For Vim version 8.2. Last change: 2020 Jun 01
|
||||
*usr_41.txt* For Vim version 8.2. Last change: 2020 Jun 13
|
||||
|
||||
VIM USER MANUAL - by Bram Moolenaar
|
||||
|
||||
@ -41,10 +41,11 @@ prefer. And you can use any colon command in it (commands that start with a
|
||||
specific file type. A complicated macro can be defined by a separate Vim
|
||||
script file. You can think of other uses yourself.
|
||||
|
||||
Note: if you are familiar with Python, you can find a comparison between
|
||||
Python and Vim script here, with pointers to other documents:
|
||||
https://gist.github.com/yegappan/16d964a37ead0979b05e655aa036cad0
|
||||
|
||||
If you are familiar with Python, you can find a comparison between
|
||||
Python and Vim script here, with pointers to other documents:
|
||||
https://gist.github.com/yegappan/16d964a37ead0979b05e655aa036cad0
|
||||
And if you are familiar with Javascript:
|
||||
https://w0rp.com/blog/post/vim-script-for-the-javascripter/
|
||||
|
||||
Let's start with a simple example: >
|
||||
|
||||
@ -98,6 +99,8 @@ and the value of the variable i. Since i is one, this will print:
|
||||
Then there is the ":let i += 1" command. This does the same thing as
|
||||
":let i = i + 1". This adds one to the variable i and assigns the new value
|
||||
to the same variable.
|
||||
Note: this is how it works in legacy Vim script, which is what we discuss in
|
||||
this file. In Vim9 script it's a bit different, see |usr_46.txt|.
|
||||
|
||||
The example was given to explain the commands, but would you really want to
|
||||
make such a loop, it can be written much more compact: >
|
||||
|
||||
Reference in New Issue
Block a user