Skip to content

Commit fe25a90

Browse files
committed
Merge remote-tracking branch 'vim/master'
2 parents edd4d38 + 701c863 commit fe25a90

File tree

93 files changed

+1328
-365
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

93 files changed

+1328
-365
lines changed

.github/MAINTAINERS

+7
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ nsis/lang/russian.nsi @RestorerZ
1313
runtime/autoload/freebasic.vim @dkearns
1414
runtime/autoload/hare.vim @selenebun
1515
runtime/autoload/haskell.vim @alx741
16+
runtime/autoload/hcl.vim @gpanders
1617
runtime/autoload/javascript.vim @jsit
1718
runtime/autoload/modula2.vim @dkearns
1819
runtime/autoload/php.vim @david-szabo97
@@ -170,6 +171,7 @@ runtime/ftplugin/haml.vim @tpope
170171
runtime/ftplugin/hare.vim @selenebun
171172
runtime/ftplugin/haredoc.vim @selenebun
172173
runtime/ftplugin/heex.vim @cvincent
174+
runtime/ftplugin/hcl.vim @gpanders
173175
runtime/ftplugin/hgcommit.vim @k-takata
174176
runtime/ftplugin/hlsplaylist.vim @avidseeker
175177
runtime/ftplugin/hog.vim @wtfbbqhax
@@ -213,6 +215,7 @@ runtime/ftplugin/nginx.vim @chr4
213215
runtime/ftplugin/nim.vim @ribru17
214216
runtime/ftplugin/nroff.vim @a-vrma
215217
runtime/ftplugin/nsis.vim @k-takata
218+
runtime/ftplugin/nu.vim @mrcjkb
216219
runtime/ftplugin/octave.vim @dkearns
217220
runtime/ftplugin/ondir.vim @jparise
218221
runtime/ftplugin/openvpn.vim @ObserverOfTime
@@ -315,6 +318,7 @@ runtime/indent/go.vim @dbarnett
315318
runtime/indent/gyp.vim @ObserverOfTime
316319
runtime/indent/haml.vim @tpope
317320
runtime/indent/hare.vim @selenebun
321+
runtime/indent/hcl.vim @gpanders
318322
runtime/indent/hog.vim @wtfbbqhax
319323
runtime/indent/idlang.vim @dkearns
320324
runtime/indent/j.vim @glts
@@ -359,6 +363,7 @@ runtime/indent/systemverilog.vim @Kocha
359363
runtime/indent/tcl.vim @dkearns
360364
runtime/indent/tcsh.vim @dkearns
361365
runtime/indent/teraterm.vim @k-takata
366+
runtime/indent/terraform.vim @gpanders
362367
runtime/indent/thrift.vim @jiangyinzuo
363368
runtime/indent/typescript.vim @HerringtonDarkholme
364369
runtime/indent/typst.vim @gpanders
@@ -458,6 +463,7 @@ runtime/syntax/haml.vim @tpope
458463
runtime/syntax/hare.vim @selenebun
459464
runtime/syntax/haredoc.vim @selenebun
460465
runtime/syntax/haskell.vim @coot
466+
runtime/syntax/hcl.vim @gpanders
461467
runtime/syntax/help_ru.vim @RestorerZ
462468
runtime/syntax/hgcommit.vim @k-takata
463469
runtime/syntax/hitest.vim @lacygoill
@@ -565,6 +571,7 @@ runtime/syntax/systemverilog.vim @Kocha
565571
runtime/syntax/tap.vim @petdance
566572
runtime/syntax/tcsh.vim @dkearns
567573
runtime/syntax/teraterm.vim @k-takata
574+
runtime/syntax/terraform.vim @gpanders
568575
runtime/syntax/thrift.vim @jiangyinzuo
569576
runtime/syntax/tidy.vim @dkearns
570577
runtime/syntax/tmux.vim @ericpruitt

runtime/autoload/getscript.vim

+20-12
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@
66
" Version: 36
77
" Installing: :help glvs-install
88
" Usage: :help glvs
9+
" Last Change: {{{1
10+
" 2024 Sep 08 by Vim Project: several small fixes
11+
" }}}
912
"
1013
" GetLatestVimScripts: 642 1 :AutoInstall: getscript.vim
1114
"redraw!|call inputsave()|call input("Press <cr> to continue")|call inputrestore()
@@ -64,7 +67,7 @@ if !exists("g:GetLatestVimScripts_options")
6467
if g:GetLatestVimScripts_wget == "wget"
6568
let g:GetLatestVimScripts_options= "-q -O"
6669
elseif g:GetLatestVimScripts_wget == "curl"
67-
let g:GetLatestVimScripts_options= "-s -O"
70+
let g:GetLatestVimScripts_options= "-s -o"
6871
else
6972
let g:GetLatestVimScripts_options= ""
7073
endif
@@ -77,7 +80,11 @@ endif
7780

7881
" set up default scriptaddr address
7982
if !exists("g:GetLatestVimScripts_scriptaddr")
80-
let g:GetLatestVimScripts_scriptaddr = 'http://vim.sourceforge.net/script.php?script_id='
83+
let g:GetLatestVimScripts_scriptaddr = 'https://www.vim.org/scripts/script.php?script_id='
84+
endif
85+
86+
if !exists("g:GetLatestVimScripts_downloadaddr")
87+
let g:GetLatestVimScripts_downloadaddr = 'https://www.vim.org/scripts/download_script.php?src_id='
8188
endif
8289

8390
"" For debugging:
@@ -89,11 +96,11 @@ endif
8996
let s:autoinstall= ""
9097
if g:GetLatestVimScripts_allowautoinstall
9198

92-
if (has("win32") || has("gui_win32") || has("gui_win32s") || has("win16") || has("win64") || has("win32unix") || has("win95")) && &shell != "bash"
99+
if (has("win32") || has("gui_win32") || has("gui_win32s") || has("win16") || has("win64") || has("win32unix") || has("win95")) && &shell !~ '\cbash\|pwsh\|powershell'
93100
" windows (but not cygwin/bash)
94101
let s:dotvim= "vimfiles"
95102
if !exists("g:GetLatestVimScripts_mv")
96-
let g:GetLatestVimScripts_mv= "ren"
103+
let g:GetLatestVimScripts_mv= "move"
97104
endif
98105

99106
else
@@ -208,9 +215,10 @@ fun! getscript#GetLatestVimScripts()
208215
" call Decho("searching plugins for GetLatestVimScripts dependencies")
209216
let lastline = line("$")
210217
" call Decho("lastline#".lastline)
211-
let firstdir = substitute(&rtp,',.*$','','')
218+
let firstdir = substitute(&rtp,',.{-}$','','')
212219
let plugins = split(globpath(firstdir,"plugin/**/*.vim"),'\n')
213-
let plugins = plugins + split(globpath(firstdir,"AsNeeded/**/*.vim"),'\n')
220+
let plugins += split(globpath(firstdir,"ftplugin/**/*.vim"),'\n')
221+
let plugins += split(globpath(firstdir,"AsNeeded/**/*.vim"),'\n')
214222
let foundscript = 0
215223

216224
" this loop updates the GetLatestVimScripts.dat file
@@ -515,11 +523,11 @@ fun! s:GetOneScript(...)
515523
" call Decho(".downloading new <".sname.">")
516524
echomsg ".downloading new <".sname.">"
517525
if has("win32") || has("win16") || has("win95")
518-
" call Decho(".new|exe silent r!".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape('http://vim.sourceforge.net/scripts/download_script.php?src_id='.latestsrcid)."|q")
519-
new|exe "silent r!".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape('http://vim.sourceforge.net/scripts/download_script.php?src_id='.latestsrcid)|q
526+
" call Decho(".new|exe silent r!".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape(g:GetLatestVimScripts_downloadaddr.latestsrcid)."|q")
527+
new|exe "silent r!".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape(g:GetLatestVimScripts_downloadaddr.latestsrcid)|q
520528
else
521-
" call Decho(".exe silent !".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape('http://vim.sourceforge.net/scripts/download_script.php?src_id='))
522-
exe "silent !".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape('http://vim.sourceforge.net/scripts/download_script.php?src_id=').latestsrcid
529+
" call Decho(".exe silent !".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape(g:GetLatestVimScripts_downloadaddr).latestsrcid
530+
exe "silent !".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape(g:GetLatestVimScripts_downloadaddr).latestsrcid
523531
endif
524532

525533
" --------------------------------------------------------------------------
@@ -573,7 +581,7 @@ fun! s:GetOneScript(...)
573581
" call Decho("no decompression needed")
574582
endif
575583

576-
" distribute archive(.zip, .tar, .vba, ...) contents
584+
" distribute archive(.zip, .tar, .vba, .vmb, ...) contents
577585
if sname =~ '\.zip$'
578586
" call Decho("dearchive: attempt to unzip ".sname)
579587
exe "silent !unzip -o ".shellescape(sname)
@@ -592,7 +600,7 @@ fun! s:GetOneScript(...)
592600
elseif sname =~ '\.txz$'
593601
" call Decho("dearchive: attempt to untar+xz ".sname)
594602
exe "silent !tar -Jxvf ".shellescape(sname)
595-
elseif sname =~ '\.vba$'
603+
elseif sname =~ '\.vba$\|\.vmb$'
596604
" call Decho("dearchive: attempt to handle a vimball: ".sname)
597605
silent 1split
598606
if exists("g:vimball_home")

runtime/autoload/hcl.vim

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
" Language: HCL
2+
" Maintainer: Gregory Anders
3+
" Last Change: 2024-09-03
4+
" Based on: https://github.com/hashivim/vim-terraform
5+
6+
function! hcl#indentexpr(lnum)
7+
" Beginning of the file should have no indent
8+
if a:lnum == 0
9+
return 0
10+
endif
11+
12+
" Usual case is to continue at the same indent as the previous non-blank line.
13+
let prevlnum = prevnonblank(a:lnum-1)
14+
let thisindent = indent(prevlnum)
15+
16+
" If that previous line is a non-comment ending in [ { (, increase the
17+
" indent level.
18+
let prevline = getline(prevlnum)
19+
if prevline !~# '^\s*\(#\|//\)' && prevline =~# '[\[{\(]\s*$'
20+
let thisindent += &shiftwidth
21+
endif
22+
23+
" If the current line ends a block, decrease the indent level.
24+
let thisline = getline(a:lnum)
25+
if thisline =~# '^\s*[\)}\]]'
26+
let thisindent -= &shiftwidth
27+
endif
28+
29+
" If the previous line starts a block comment /*, increase by one
30+
if prevline =~# '/\*'
31+
let thisindent += 1
32+
endif
33+
34+
" If the previous line ends a block comment */, decrease by one
35+
if prevline =~# '\*/'
36+
let thisindent -= 1
37+
endif
38+
39+
return thisindent
40+
endfunction

runtime/doc/insert.txt

+5-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*insert.txt* For Vim version 9.1. Last change: 2024 Aug 23
1+
*insert.txt* For Vim version 9.1. Last change: 2024 Aug 25
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -1191,9 +1191,10 @@ items:
11911191
to the completion items
11921192
kind_hlgroup an additional highlight group specifically for setting
11931193
the highlight attributes of the completion kind. When
1194-
this field is present, it will override the |hl-PmenuKind|
1195-
highlight group, allowing for the customization of
1196-
ctermfd and guifg properties for the completion kind
1194+
this field is present, it will override the
1195+
|hl-PmenuKind| highlight group, allowing for the
1196+
customization of ctermfg and guifg properties for the
1197+
completion kind
11971198

11981199
All of these except "icase", "equal", "dup" and "empty" must be a string. If
11991200
an item does not meet these requirements then an error message is given and

runtime/doc/map.txt

+7-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*map.txt* For Vim version 9.1. Last change: 2024 Jul 11
1+
*map.txt* For Vim version 9.1. Last change: 2024 Aug 31
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -1624,12 +1624,14 @@ completion can be enabled:
16241624

16251625
-complete=arglist file names in argument list
16261626
-complete=augroup autocmd groups
1627+
-complete=behave |:behave| suboptions
1628+
-complete=breakpoint |:breakadd| suboptions
16271629
-complete=buffer buffer names
1628-
-complete=behave :behave suboptions
16291630
-complete=color color schemes
16301631
-complete=command Ex command (and arguments)
16311632
-complete=compiler compilers
16321633
-complete=cscope |:cscope| suboptions
1634+
-complete=diff_buffer diff buffer names
16331635
-complete=dir directory names
16341636
-complete=dir_in_path directory names in |'cdpath'|
16351637
-complete=environment environment variable names
@@ -1641,7 +1643,7 @@ completion can be enabled:
16411643
-complete=function function name
16421644
-complete=help help subjects
16431645
-complete=highlight highlight groups
1644-
-complete=history :history suboptions
1646+
-complete=history |:history| suboptions
16451647
-complete=keymap keyboard mappings
16461648
-complete=locale locale names (as output of locale -a)
16471649
-complete=mapclear buffer argument
@@ -1650,6 +1652,8 @@ completion can be enabled:
16501652
-complete=messages |:messages| suboptions
16511653
-complete=option options
16521654
-complete=packadd optional package |pack-add| names
1655+
-complete=runtime file and directory names in |'runtimepath'|
1656+
-complete=scriptnames sourced script names
16531657
-complete=shellcmd Shell command
16541658
-complete=sign |:sign| suboptions
16551659
-complete=syntax syntax file names |'syntax'|

runtime/doc/motion.txt

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*motion.txt* For Vim version 9.1. Last change: 2024 Jul 14
1+
*motion.txt* For Vim version 9.1. Last change: 2024 Aug 28
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -364,11 +364,11 @@ gg Goto line [count], default first line, on the first
364364
See also 'startofline' option.
365365

366366
:[range]go[to] [count] *:go* *:goto* *go*
367-
[count]go Go to [count] byte in the buffer. Default [count] is
368-
one, start of the file. When giving [range], the
369-
last number in it used as the byte count. End-of-line
370-
characters are counted depending on the current
371-
'fileformat' setting.
367+
[count]go Go to [count] byte in the buffer. |exclusive| motion.
368+
Default [count] is one, start of the file. When
369+
giving [range], the last number in it used as the byte
370+
count. End-of-line characters are counted depending
371+
on the current 'fileformat' setting.
372372
Also see the |line2byte()| function, and the 'o'
373373
option in 'statusline'.
374374
{not available when compiled without the

runtime/doc/options.txt

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*options.txt* For Vim version 9.1. Last change: 2024 Aug 12
1+
*options.txt* For Vim version 9.1. Last change: 2024 Sep 07
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -1496,9 +1496,9 @@ A jump table for the options with a short description can be found at |Q_op|.
14961496
list:{n} Adds an additional indent for lines that match a
14971497
numbered or bulleted list (using the
14981498
'formatlistpat' setting).
1499-
list:-1 Uses the length of a match with 'formatlistpat'
1500-
for indentation.
15011499
(default: 0)
1500+
list:-1 Uses the width of a match with 'formatlistpat' for
1501+
indentation.
15021502
column:{n} Indent at column {n}. Will overrule the other
15031503
sub-options. Note: an additional indent may be
15041504
added for the 'showbreak' setting.

runtime/doc/pi_getscript.txt

+20-12
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*pi_getscript.txt* For Vim version 9.1. Last change: 2017 Aug 01
1+
*pi_getscript.txt* For Vim version 9.1. Last change: 2024 Sep 08
22
>
33
GETSCRIPT REFERENCE MANUAL by Charles E. Campbell
44
<
@@ -20,7 +20,7 @@ Copyright: (c) 2004-2012 by Charles E. Campbell *glvs-copyright*
2020
Getscript is a plugin that simplifies retrieval of the latest versions of the
2121
scripts that you yourself use! Typing |:GLVS| will invoke getscript; it will
2222
then use the <GetLatestVimScripts.dat> (see |GetLatestVimScripts_dat|) file to
23-
get the latest versions of scripts listed therein from http://vim.sf.net/.
23+
get the latest versions of scripts listed therein from https://www.vim.org/.
2424

2525
==============================================================================
2626
1. Contents *glvs-contents* *glvs* *getscript*
@@ -59,9 +59,9 @@ the "important" part of it is the first two lines.
5959

6060
Your computer needs to have wget or curl for GetLatestVimScripts to do its work.
6161

62-
1. if compressed: gunzip getscript.vba.gz
62+
1. if compressed: gunzip getscript.vmb.gz
6363
2. Unix:
64-
vim getscript.vba
64+
vim getscript.vmb
6565
:so %
6666
:q
6767
cd ~/.vim/GetLatest
@@ -70,7 +70,7 @@ Your computer needs to have wget or curl for GetLatestVimScripts to do its work.
7070
list of desired plugins -- see |GetLatestVimScripts_dat|)
7171

7272
3. Windows:
73-
vim getscript.vba
73+
vim getscript.vmb
7474
:so %
7575
:q
7676
cd **path-to-vimfiles**/GetLatest
@@ -281,11 +281,14 @@ With :AutoInstall: enabled, as it is by default, files which end with
281281

282282
---.tar.bz2 : decompressed & untarred in .vim/ directory
283283
---.vba.bz2 : decompressed in .vim/ directory, then vimball handles it
284+
---.vmb.bz2 : decompressed in .vim/ directory, then vimball handles it
284285
---.vim.bz2 : decompressed & moved into .vim/plugin directory
285286
---.tar.gz : decompressed & untarred in .vim/ directory
286287
---.vba.gz : decompressed in .vim/ directory, then vimball handles it
288+
---.vmb.gz : decompressed in .vim/ directory, then vimball handles it
287289
---.vim.gz : decompressed & moved into .vim/plugin directory
288-
---.vba : unzipped in .vim/ directory
290+
---.vba : moved to .vim/ directory, then vimball handles it
291+
---.vmb : moved to .vim/ directory, then vimball handles it
289292
---.vim : moved to .vim/plugin directory
290293
---.zip : unzipped in .vim/ directory
291294

@@ -300,7 +303,7 @@ When is a script not auto-installable? Let me give an example:
300303
The <blockhl.vim> script provides block highlighting for C/C++ programs; it is
301304
available at:
302305

303-
http://vim.sourceforge.net/scripts/script.php?script_id=104
306+
https://www.vim.org/scripts/script.php?script_id=104
304307

305308
Currently, vim's after/syntax only supports by-filetype scripts (in
306309
blockhl.vim's case, that's after/syntax/c.vim). Hence, auto-install would
@@ -309,7 +312,7 @@ possibly overwrite the current user's after/syntax/c.vim file.
309312
In my own case, I use <aftersyntax.vim> (renamed to after/syntax/c.vim) to
310313
allow a after/syntax/c/ directory:
311314

312-
http://vim.sourceforge.net/scripts/script.php?script_id=1023
315+
https://www.vim.org/scripts/script.php?script_id=1023
313316

314317
The script allows multiple syntax files to exist separately in the
315318
after/syntax/c subdirectory. I can't bundle aftersyntax.vim in and build an
@@ -345,17 +348,22 @@ after/syntax/c.vim contained in it to overwrite a user's c.vim.
345348
Doesn't override vimball installation.
346349
>
347350
g:GetLatestVimScripts_scriptaddr
348-
< default='http://vim.sourceforge.net/script.php?script_id='
351+
< default='https://www.vim.org/scripts/script.php?script_id='
349352
Override this if your system needs
350-
... ='http://vim.sourceforge.net/script/script.php?script_id='
351-
353+
... ='http://vim.sourceforge.net/script.php?script_id='
354+
>
355+
g:GetLatestVimScripts_downloadaddr
356+
< default='https://www.vim.org/scripts/download_script.php?src_id='
357+
Override this if your system needs
358+
... ='http://vim.sourceforge.net/scripts/download_script.php?src_id='
359+
>
352360
==============================================================================
353361
8. GetLatestVimScripts Algorithm *glvs-algorithm* *glvs-alg*
354362

355363
The Vim sourceforge page dynamically creates a page by keying off of the
356364
so-called script-id. Within the webpage of
357365

358-
http://vim.sourceforge.net/scripts/script.php?script_id=40
366+
https://www.vim.org/scripts/script.php?script_id=40
359367

360368
is a line specifying the latest source-id (src_id). The source identifier
361369
numbers are always increasing, hence if the src_id is greater than the one

0 commit comments

Comments
 (0)