summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.github/MAINTAINERS (renamed from .github/CODEOWNERS)2
-rw-r--r--CONTRIBUTING.md21
-rw-r--r--Filelist2
-rw-r--r--README.md2
-rw-r--r--runtime/autoload/dist/ft.vim8
-rw-r--r--runtime/autoload/netrw.vim140
-rw-r--r--runtime/autoload/netrwSettings.vim3
-rw-r--r--runtime/doc/autocmd.txt6
-rw-r--r--runtime/doc/builtin.txt26
-rw-r--r--runtime/doc/change.txt4
-rw-r--r--runtime/doc/debug.txt4
-rw-r--r--runtime/doc/develop.txt4
-rw-r--r--runtime/doc/eval.txt4
-rw-r--r--runtime/doc/gui.txt5
-rw-r--r--runtime/doc/if_cscop.txt4
-rw-r--r--runtime/doc/indent.txt2
-rw-r--r--runtime/doc/map.txt10
-rw-r--r--runtime/doc/mbyte.txt19
-rw-r--r--runtime/doc/netbeans.txt14
-rw-r--r--runtime/doc/options.txt6
-rw-r--r--runtime/doc/os_vms.txt3
-rw-r--r--runtime/doc/os_win32.txt5
-rw-r--r--runtime/doc/pi_netrw.txt122
-rw-r--r--runtime/doc/pi_tar.txt5
-rw-r--r--runtime/doc/print.txt21
-rw-r--r--runtime/doc/spell.txt4
-rw-r--r--runtime/doc/starting.txt10
-rw-r--r--runtime/doc/syntax.txt14
-rw-r--r--runtime/doc/tags5
-rw-r--r--runtime/doc/tagsrch.txt3
-rw-r--r--runtime/doc/term.txt6
-rw-r--r--runtime/doc/test_urls.vim6
-rw-r--r--runtime/doc/testing.txt30
-rw-r--r--runtime/doc/todo.txt33
-rw-r--r--runtime/doc/usr_01.txt4
-rw-r--r--runtime/doc/usr_41.txt3
-rw-r--r--runtime/doc/usr_52.txt4
-rw-r--r--runtime/doc/version9.txt9
-rw-r--r--runtime/doc/xxd-it.15
-rw-r--r--runtime/doc/xxd-it.UTF-8.15
-rw-r--r--runtime/doc/xxd.17
-rw-r--r--runtime/doc/xxd.man54
-rw-r--r--runtime/filetype.vim14
-rw-r--r--runtime/ftplugin/jj.vim19
-rw-r--r--runtime/ftplugin/python.vim23
-rw-r--r--runtime/ftplugin/sh.vim6
-rw-r--r--runtime/ftplugin/zsh.vim4
-rw-r--r--runtime/plugin/netrwPlugin.vim4
-rw-r--r--runtime/syntax/cpp.vim9
-rw-r--r--runtime/syntax/java.vim168
-rw-r--r--runtime/syntax/jj.vim20
-rw-r--r--runtime/syntax/spec.vim2
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent2_00.dump12
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent2_01.dump8
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent2_03.dump2
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent2_04.dump4
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent2_99.dump14
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent4_00.dump12
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent4_01.dump8
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent4_03.dump2
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent4_04.dump2
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent4_99.dump14
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent8_00.dump12
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent8_01.dump8
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent8_03.dump2
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent8_04.dump2
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_indent8_99.dump14
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_style_00.dump12
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_style_01.dump8
-rw-r--r--runtime/syntax/testdir/dumps/java_methods_style_03.dump2
-rw-r--r--runtime/syntax/testdir/input/java_methods_indent2.java28
-rw-r--r--runtime/syntax/testdir/input/java_methods_indent4.java28
-rw-r--r--runtime/syntax/testdir/input/java_methods_indent8.java28
-rw-r--r--runtime/syntax/testdir/input/java_methods_style.java14
-rwxr-xr-xsrc/auto/configure8
-rw-r--r--src/configure.ac6
-rw-r--r--src/eval.c1263
-rw-r--r--src/evalfunc.c327
-rw-r--r--src/mouse.c22
-rw-r--r--src/move.c21
-rw-r--r--src/ops.c2
-rw-r--r--src/quickfix.c7
-rw-r--r--src/regexp.c410
-rw-r--r--src/regexp_bt.c39
-rw-r--r--src/regexp_nfa.c5
-rw-r--r--src/scriptfile.c2
-rw-r--r--src/testdir/dumps/Test_smoothscroll_in_qf_window_1.dump20
-rw-r--r--src/testdir/dumps/Test_smoothscroll_in_qf_window_2.dump20
-rw-r--r--src/testdir/dumps/Test_smoothscroll_in_qf_window_3.dump20
-rw-r--r--src/testdir/dumps/Test_smoothscroll_in_qf_window_4.dump20
-rw-r--r--src/testdir/dumps/Test_smoothscroll_in_qf_window_5.dump20
-rw-r--r--src/testdir/test_blob.vim12
-rw-r--r--src/testdir/test_filetype.vim5
-rw-r--r--src/testdir/test_functions.vim67
-rw-r--r--src/testdir/test_normal.vim8
-rw-r--r--src/testdir/test_scroll_opt.vim45
-rw-r--r--src/testdir/test_vim9_assign.vim2
-rw-r--r--src/testdir/test_vim9_builtin.vim22
-rw-r--r--src/testdir/test_vim9_import.vim89
-rw-r--r--src/testdir/test_vim9_script.vim17
-rw-r--r--src/testdir/test_vim9_typealias.vim2
-rw-r--r--src/testdir/test_visual.vim85
-rw-r--r--src/testdir/test_xxd.vim16
-rw-r--r--src/version.c36
-rw-r--r--src/vim9type.c7
-rw-r--r--src/xxd/xxd.c34
106 files changed, 2478 insertions, 1330 deletions
diff --git a/.github/CODEOWNERS b/.github/MAINTAINERS
index ac41ed5678..36b352ffbf 100644
--- a/.github/CODEOWNERS
+++ b/.github/MAINTAINERS
@@ -161,6 +161,7 @@ runtime/ftplugin/j.vim @glts
runtime/ftplugin/java.vim @zzzyxwvut
runtime/ftplugin/javascript.vim @dkearns
runtime/ftplugin/javascriptreact.vim @dkearns
+runtime/ftplugin/jj.vim @gpanders
runtime/ftplugin/json.vim @dbarnett
runtime/ftplugin/json5.vim @dkearns
runtime/ftplugin/jsonc.vim @izhakjakov
@@ -406,6 +407,7 @@ runtime/syntax/j.vim @glts
runtime/syntax/jargon.vim @h3xx
runtime/syntax/java.vim @zzzyxwvut
runtime/syntax/javascript.vim @fleiner
+runtime/syntax/jj.vim @gpanders
runtime/syntax/json.vim @vito-c
runtime/syntax/jsonc.vim @izhakjakov
runtime/syntax/julia.vim @carlobaldassi
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 0720cb1699..99bfcfa2c8 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -46,17 +46,30 @@ Or open [the todo file][todo list] on GitHub to see the latest version.
# Syntax, indent and other runtime files
The latest version of these files can be obtained from the repository.
-They are usually not updated with numbered patches.
+They are usually not updated with numbered patches. However, they may
+or may not work with older Vim releases (since they may contain new features).
If you find a problem with one of these files or have a suggestion for
improvement, please first try to contact the maintainer directly.
-Look in the header of the file for the name and email address.
+Look in the header of the file for the name, email address, github handle and/or
+upstream repository. You may also check the [MAINTAINERS][11] file.
The maintainer will take care of issues and send updates to the Vim project for
distribution with Vim.
If the maintainer does not respond, contact the [vim-dev][0] mailing list.
+## Contributing new runtime files
+
+If you want to contribute new runtime files for Vim or Neovim, please create a
+PR with your changes against this repository here. For new filetypes, do not forget:
+* to add a new [filetype test][12] (keep it similar to the other filetype tests).
+* all configuration switches should be documented
+ (check [filetype.txt][13] and/or [syntax.txt][14] for filetype and syntax plugins)
+* add yourself as Maintainer to the top of file (again, keep the header similar to
+ other runtime files)
+* add yourself to the [MAINTAINERS][11] file.
+
# Translations
Translating messages and runtime files is very much appreciated! These things
@@ -96,3 +109,7 @@ mailing list. For other questions please use the [Vi Stack Exchange][8] website,
[8]: https://vi.stackexchange.com
[9]: http://www.vim.org/maillist.php#vim-use
[10]: https://github.com/vim/vim/discussions
+[11]: https://github.com/vim/vim/blob/master/.github/MAINTAINERS
+[12]: https://github.com/vim/vim/blob/master/src/testdir/test_filetype.vim
+[13]: https://github.com/vim/vim/blob/master/runtime/doc/filetype.txt
+[14]: https://github.com/vim/vim/blob/master/runtime/doc/syntax.txt
diff --git a/Filelist b/Filelist
index ff474bc642..771854812f 100644
--- a/Filelist
+++ b/Filelist
@@ -5,7 +5,7 @@
SRC_ALL = \
.cirrus.yml \
.gitattributes \
- .github/CODEOWNERS \
+ .github/MAINTAINERS \
.github/ISSUE_TEMPLATE/bug_report.yml \
.github/ISSUE_TEMPLATE/feature_request.md \
.github/workflows/ci.yml \
diff --git a/README.md b/README.md
index 6e6cf11b89..5ac3a6c997 100644
--- a/README.md
+++ b/README.md
@@ -18,7 +18,7 @@ or one of the [Maillists](https://www.vim.org/community.php).
## What is Vim?
Vim is a greatly improved version of the good old UNIX editor
-[Vi](https://en.wikipedia.org/wiki/Vi). Many new
+[Vi](https://en.wikipedia.org/wiki/Vi_(text_editor)). Many new
features have been added: multi-level undo, syntax highlighting, command line
history, on-line help, spell checking, filename completion, block operations,
script language, etc. There is also a Graphical User Interface (GUI)
diff --git a/runtime/autoload/dist/ft.vim b/runtime/autoload/dist/ft.vim
index 4e7d517931..dd4fd30636 100644
--- a/runtime/autoload/dist/ft.vim
+++ b/runtime/autoload/dist/ft.vim
@@ -406,14 +406,18 @@ export def FTidl()
setf idl
enddef
-# Distinguish between "default", Prolog and Cproto prototype file.
+# Distinguish between "default", Prolog, zsh module's C and Cproto prototype file.
export def ProtoCheck(default: string)
+ # zsh modules use '#include "*.pro"'
+ # https://github.com/zsh-users/zsh/blob/63f086d167960a27ecdbcb762179e2c2bf8a29f5/Src/Modules/example.c#L31
+ if getline(1) =~ '/* Generated automatically */'
+ setf c
# Cproto files have a comment in the first line and a function prototype in
# the second line, it always ends in ";". Indent files may also have
# comments, thus we can't match comments to see the difference.
# IDL files can have a single ';' in the second line, require at least one
# chacter before the ';'.
- if getline(2) =~ '.;$'
+ elseif getline(2) =~ '.;$'
setf cpp
else
# recognize Prolog by specific text in the first non-empty line
diff --git a/runtime/autoload/netrw.vim b/runtime/autoload/netrw.vim
index e2152b0dfc..4c95d2c715 100644
--- a/runtime/autoload/netrw.vim
+++ b/runtime/autoload/netrw.vim
@@ -9,6 +9,9 @@
" 2024 Feb 19 by Vim Project: (announce adoption)
" 2024 Feb 29 by Vim Project: handle symlinks in tree mode correctly
" 2024 Apr 03 by Vim Project: detect filetypes for remote edited files
+" 2024 May 08 by Vim Project: cleanup legacy Win9X checks
+" 2024 May 09 by Vim Project: remove hard-coded private.ppk
+" 2024 May 10 by Vim Project: recursively delete directories by default
" Former Maintainer: Charles E Campbell
" GetLatestVimScripts: 1075 1 :AutoInstall: netrw.vim
" Copyright: Copyright (C) 2016 Charles E. Campbell {{{1
@@ -280,14 +283,8 @@ call s:NetrwInit("g:netrw_rcp_cmd" , "rcp")
call s:NetrwInit("g:netrw_rsync_cmd", "rsync")
call s:NetrwInit("g:netrw_rsync_sep", "/")
if !exists("g:netrw_scp_cmd")
- if executable("scp")
- call s:NetrwInit("g:netrw_scp_cmd" , "scp -q")
- elseif executable("pscp")
- if (has("win32") || has("win95") || has("win64") || has("win16")) && filereadable('c:\private.ppk')
- call s:NetrwInit("g:netrw_scp_cmd", 'pscp -i c:\private.ppk')
- else
- call s:NetrwInit("g:netrw_scp_cmd", 'pscp -q')
- endif
+ if executable("pscp")
+ call s:NetrwInit("g:netrw_scp_cmd", 'pscp -q')
else
call s:NetrwInit("g:netrw_scp_cmd" , "scp -q")
endif
@@ -296,7 +293,7 @@ endif
call s:NetrwInit("g:netrw_sftp_cmd" , "sftp")
call s:NetrwInit("g:netrw_ssh_cmd" , "ssh")
-if (has("win32") || has("win95") || has("win64") || has("win16"))
+if has("win32")
\ && exists("g:netrw_use_nt_rcp")
\ && g:netrw_use_nt_rcp
\ && executable( $SystemRoot .'/system32/rcp.exe')
@@ -311,12 +308,8 @@ endif
" Default values for netrw's global variables {{{2
" Cygwin Detection ------- {{{3
if !exists("g:netrw_cygwin")
- if has("win32") || has("win95") || has("win64") || has("win16")
- if has("win32unix") && &shell =~ '\%(\<bash\>\|\<zsh\>\)\%(\.exe\)\=$'
- let g:netrw_cygwin= 1
- else
- let g:netrw_cygwin= 0
- endif
+ if has("win32unix") && &shell =~ '\%(\<bash\>\|\<zsh\>\)\%(\.exe\)\=$'
+ let g:netrw_cygwin= 1
else
let g:netrw_cygwin= 0
endif
@@ -372,10 +365,6 @@ endif
call s:NetrwInit("g:netrw_keepdir",1)
if !exists("g:netrw_list_cmd")
if g:netrw_scp_cmd =~ '^pscp' && executable("pscp")
- if (has("win32") || has("win95") || has("win64") || has("win16")) && filereadable("c:\\private.ppk")
- " provide a pscp-based listing command
- let g:netrw_scp_cmd ="pscp -i C:\\private.ppk"
- endif
if exists("g:netrw_list_cmd_options")
let g:netrw_list_cmd= g:netrw_scp_cmd." -ls USEPORT HOSTNAME: ".g:netrw_list_cmd_options
else
@@ -403,7 +392,7 @@ if !exists("g:netrw_localcmdshell")
let g:netrw_localcmdshell= ""
endif
if !exists("g:netrw_localcopycmd")
- if has("win32") || has("win95") || has("win64") || has("win16")
+ if has("win32")
if g:netrw_cygwin
let g:netrw_localcopycmd= "cp"
else
@@ -417,7 +406,7 @@ if !exists("g:netrw_localcopycmd")
endif
endif
if !exists("g:netrw_localcopydircmd")
- if has("win32") || has("win95") || has("win64") || has("win16")
+ if has("win32")
if g:netrw_cygwin
let g:netrw_localcopydircmd = "cp"
let g:netrw_localcopydircmdopt= " -R"
@@ -439,7 +428,7 @@ if exists("g:netrw_local_mkdir")
let g:netrw_localmkdir= g:netrw_local_mkdir
call netrw#ErrorMsg(s:NOTE,"g:netrw_local_mkdir is deprecated in favor of g:netrw_localmkdir",87)
endif
-if has("win32") || has("win95") || has("win64") || has("win16")
+if has("win32")
if g:netrw_cygwin
call s:NetrwInit("g:netrw_localmkdir","mkdir")
else
@@ -455,7 +444,7 @@ if exists("g:netrw_local_movecmd")
call netrw#ErrorMsg(s:NOTE,"g:netrw_local_movecmd is deprecated in favor of g:netrw_localmovecmd",88)
endif
if !exists("g:netrw_localmovecmd")
- if has("win32") || has("win95") || has("win64") || has("win16")
+ if has("win32")
if g:netrw_cygwin
let g:netrw_localmovecmd= "mv"
else
@@ -488,7 +477,7 @@ call s:NetrwInit("g:netrw_mousemaps" , (exists("+mouse") && &mouse =~# '[anh
call s:NetrwInit("g:netrw_retmap" , 0)
if has("unix") || (exists("g:netrw_cygwin") && g:netrw_cygwin)
call s:NetrwInit("g:netrw_chgperm" , "chmod PERM FILENAME")
-elseif has("win32") || has("win95") || has("win64") || has("win16")
+elseif has("win32")
call s:NetrwInit("g:netrw_chgperm" , "cacls FILENAME /e /p PERM")
else
call s:NetrwInit("g:netrw_chgperm" , "chmod PERM FILENAME")
@@ -547,14 +536,13 @@ if !exists("g:netrw_xstrlen")
endif
endif
call s:NetrwInit("g:NetrwTopLvlMenu","Netrw.")
-call s:NetrwInit("g:netrw_win95ftp",1)
call s:NetrwInit("g:netrw_winsize",50)
call s:NetrwInit("g:netrw_wiw",1)
if g:netrw_winsize > 100|let g:netrw_winsize= 100|endif
" ---------------------------------------------------------------------
" Default values for netrw's script variables: {{{2
call s:NetrwInit("g:netrw_fname_escape",' ?&;%')
-if has("win32") || has("win95") || has("win64") || has("win16")
+if has("win32")
call s:NetrwInit("g:netrw_glob_escape",'*?`{[]$')
else
call s:NetrwInit("g:netrw_glob_escape",'*[]?`{~$\')
@@ -686,7 +674,7 @@ fun! netrw#Explore(indx,dosplit,style,...)
" record current directory
let curdir = simplify(b:netrw_curdir)
let curfiledir = substitute(expand("%:p"),'^\(.*[/\\]\)[^/\\]*$','\1','e')
- if !exists("g:netrw_cygwin") && (has("win32") || has("win95") || has("win64") || has("win16"))
+ if !exists("g:netrw_cygwin") && has("win32")
let curdir= substitute(curdir,'\','/','g')
endif
" call Decho("curdir<".curdir