mirror of
https://github.com/zoriya/vim.git
synced 2025-12-25 00:25:21 +00:00
Compare commits
474 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e60b3c47d7 | ||
|
|
d82a47dd04 | ||
|
|
bb8cac56d9 | ||
|
|
9d00e4a814 | ||
|
|
d3a117814d | ||
|
|
677658ae49 | ||
|
|
8e7d9db32b | ||
|
|
c653e4a2bd | ||
|
|
a6f7929e62 | ||
|
|
548911ee14 | ||
|
|
d88be5be80 | ||
|
|
6cac77016b | ||
|
|
d94fbfc74a | ||
|
|
fcd1635a46 | ||
|
|
c024ed9233 | ||
|
|
48824e952f | ||
|
|
10d6f18b2f | ||
|
|
078a46161e | ||
|
|
9acf2d8be9 | ||
|
|
ad8f248585 | ||
|
|
c88e977862 | ||
|
|
0e2508d9e6 | ||
|
|
114dbda785 | ||
|
|
5c75eed758 | ||
|
|
e982586f8e | ||
|
|
475d9521ba | ||
|
|
1d423ef75f | ||
|
|
b09feaa86e | ||
|
|
ac78dd4a35 | ||
|
|
3d0da09bb2 | ||
|
|
eaaac014a0 | ||
|
|
8bfa0eb863 | ||
|
|
2b4ecc2c31 | ||
|
|
b3bd1d39e6 | ||
|
|
a6feb163f0 | ||
|
|
6b1a99dfe3 | ||
|
|
9a846fbaa5 | ||
|
|
b34689010a | ||
|
|
cbadefe25a | ||
|
|
1f4a3457a3 | ||
|
|
0f7a5e758c | ||
|
|
3a846e6bca | ||
|
|
0699b040e6 | ||
|
|
74409f6279 | ||
|
|
56200eed62 | ||
|
|
e70cec9760 | ||
|
|
460ae5dfca | ||
|
|
b37a65e4bf | ||
|
|
b79ee0c299 | ||
|
|
654b729c4c | ||
|
|
096ca73dac | ||
|
|
d0819d11ec | ||
|
|
436b5adc97 | ||
|
|
f1474d801b | ||
|
|
6d0570117a | ||
|
|
ef089f50f9 | ||
|
|
1a9922243a | ||
|
|
4b1478093e | ||
|
|
eb822a280c | ||
|
|
9a015111a5 | ||
|
|
6ad84ab3e4 | ||
|
|
1fa3de1ce8 | ||
|
|
04fb916684 | ||
|
|
d293981d2b | ||
|
|
94f3192b03 | ||
|
|
4c13e5e676 | ||
|
|
cfe3af284a | ||
|
|
f38aad85cf | ||
|
|
1c67f3a977 | ||
|
|
13789bf103 | ||
|
|
5d2e007ccb | ||
|
|
491669701c | ||
|
|
8e7cc6b920 | ||
|
|
ab16ad33ba | ||
|
|
94fb8274ca | ||
|
|
5a664fe57f | ||
|
|
ba26367fea | ||
|
|
edc6f10390 | ||
|
|
ccc1644f95 | ||
|
|
5d20fbf2e7 | ||
|
|
5ea5f37372 | ||
|
|
3d0abad5bf | ||
|
|
264d3ddac0 | ||
|
|
febb78fa17 | ||
|
|
c97f9a55bd | ||
|
|
10c75c4a09 | ||
|
|
11ceb7d949 | ||
|
|
8c697e3698 | ||
|
|
92f246e4f9 | ||
|
|
06f6095623 | ||
|
|
7473a84cf9 | ||
|
|
4bf1006cae | ||
|
|
8bb3fe4d4d | ||
|
|
d9da86e94e | ||
|
|
90c317f224 | ||
|
|
8b6256f6ec | ||
|
|
be4e223ead | ||
|
|
a4d131d110 | ||
|
|
1cae5a0a03 | ||
|
|
8dac2acd6a | ||
|
|
4b28ba3245 | ||
|
|
af4a61a85d | ||
|
|
5da36052a4 | ||
|
|
bf7ff61af4 | ||
|
|
ef8f04b1d1 | ||
|
|
23018f2d4b | ||
|
|
bbdd3fb804 | ||
|
|
27708e6c7b | ||
|
|
c553a21e18 | ||
|
|
1f318c6eac | ||
|
|
c88ac94a0b | ||
|
|
7319981f21 | ||
|
|
71c41255f6 | ||
|
|
9c23f9bb5f | ||
|
|
71eb3ad579 | ||
|
|
8bb65f230d | ||
|
|
ec86520f94 | ||
|
|
fb9dcb080b | ||
|
|
1802405d71 | ||
|
|
db8e5c21b9 | ||
|
|
ae1068afde | ||
|
|
223d0a6bc8 | ||
|
|
5cd647935d | ||
|
|
35cfd793aa | ||
|
|
7f4a628efe | ||
|
|
d787e40fdb | ||
|
|
e7f4abd38b | ||
|
|
73a024209c | ||
|
|
806da5176e | ||
|
|
b6db146762 | ||
|
|
679140c56b | ||
|
|
6f98371532 | ||
|
|
5937c7505f | ||
|
|
fa3b72348d | ||
|
|
d3f00f54bf | ||
|
|
6073f13f55 | ||
|
|
70a120b72b | ||
|
|
51e64b2789 | ||
|
|
310091d20f | ||
|
|
28fbbeac70 | ||
|
|
f2f0bddf30 | ||
|
|
b4168fd917 | ||
|
|
a80aad7174 | ||
|
|
82b3b4c6cf | ||
|
|
080182216e | ||
|
|
f973eeb491 | ||
|
|
1aeccdb464 | ||
|
|
fa46ead31a | ||
|
|
1b5f7a6202 | ||
|
|
d92813a598 | ||
|
|
59618fed4c | ||
|
|
0d807107b6 | ||
|
|
6f79e614b2 | ||
|
|
8d95d7091d | ||
|
|
dab17a0689 | ||
|
|
39713d3acb | ||
|
|
dc7c366f3a | ||
|
|
a99fb23842 | ||
|
|
003312b1d2 | ||
|
|
2f9f4ccfc8 | ||
|
|
fea43e44c0 | ||
|
|
bc404bfb32 | ||
|
|
86b3ab4fa0 | ||
|
|
700e6b1662 | ||
|
|
f47c5a8e2d | ||
|
|
265f811f5a | ||
|
|
2de5371a75 | ||
|
|
389b72196e | ||
|
|
0ccb5842f5 | ||
|
|
605ec91e5a | ||
|
|
60618c8f1a | ||
|
|
0dc4d8eaec | ||
|
|
44a8977de4 | ||
|
|
647ab4cede | ||
|
|
422085f1c8 | ||
|
|
71b7685092 | ||
|
|
ddc80aff57 | ||
|
|
354b23a9f8 | ||
|
|
db1a410b61 | ||
|
|
d2ff705af3 | ||
|
|
02929a372e | ||
|
|
259f443a93 | ||
|
|
deda6441e4 | ||
|
|
c3f91c0648 | ||
|
|
994a0a298b | ||
|
|
23e72369ff | ||
|
|
e124204c4f | ||
|
|
94c785d235 | ||
|
|
8103527da7 | ||
|
|
f79cbf6512 | ||
|
|
b15cf44c1d | ||
|
|
52797bae17 | ||
|
|
0e6adf8a29 | ||
|
|
6df0f2759d | ||
|
|
6ecf58b0d7 | ||
|
|
2d877599ee | ||
|
|
19569ca6d8 | ||
|
|
8ee6028de3 | ||
|
|
427f065a88 | ||
|
|
c479ce032f | ||
|
|
f87dac04c3 | ||
|
|
1821d1498c | ||
|
|
ce7eada12e | ||
|
|
cfabad9bcf | ||
|
|
a5d78d1f11 | ||
|
|
57bc2333b1 | ||
|
|
7c0fb80030 | ||
|
|
b334137acf | ||
|
|
7509ad8b0f | ||
|
|
919c12c19a | ||
|
|
f8a79fc346 | ||
|
|
c2958585f6 | ||
|
|
8176be1598 | ||
|
|
6206877c51 | ||
|
|
829c8e87e2 | ||
|
|
0407d27034 | ||
|
|
3194e5bf87 | ||
|
|
6840a0ffe8 | ||
|
|
80d60910ff | ||
|
|
3b309f11db | ||
|
|
1e78deb077 | ||
|
|
851f86b951 | ||
|
|
739f13a55b | ||
|
|
33b968dc60 | ||
|
|
ef082e12df | ||
|
|
04ef1fb13d | ||
|
|
d2439e0443 | ||
|
|
3bb79dc191 | ||
|
|
fa9a8e0fd1 | ||
|
|
6ae8fae869 | ||
|
|
6e371ecb27 | ||
|
|
9a4ec5a626 | ||
|
|
4e30b5c3bc | ||
|
|
4f16e9de98 | ||
|
|
48c0196378 | ||
|
|
7b1463bca3 | ||
|
|
2ef9156b42 | ||
|
|
052ff291d7 | ||
|
|
a416861c64 | ||
|
|
29f3a45915 | ||
|
|
205f29c3e9 | ||
|
|
9537e37b11 | ||
|
|
1daedc8381 | ||
|
|
f8e9eb8e17 | ||
|
|
9fffef9f35 | ||
|
|
b711814cb6 | ||
|
|
8a7374f8c4 | ||
|
|
ff39a650b2 | ||
|
|
dd297bc11d | ||
|
|
dee78e1ce8 | ||
|
|
4c8c634365 | ||
|
|
95b2dd0c00 | ||
|
|
e8a92b6166 | ||
|
|
c4ec338fb8 | ||
|
|
dcb53be441 | ||
|
|
d0fb907253 | ||
|
|
e50507126f | ||
|
|
56150da687 | ||
|
|
a48d4e44a2 | ||
|
|
48873aebc0 | ||
|
|
78a61068cf | ||
|
|
2172bff364 | ||
|
|
f7f7aaf8aa | ||
|
|
4dc24eb5ad | ||
|
|
92c33eb273 | ||
|
|
ecabb51107 | ||
|
|
3e55a973b5 | ||
|
|
2336c376d5 | ||
|
|
8603be338a | ||
|
|
6409553b6e | ||
|
|
40bcec1bac | ||
|
|
4700398e38 | ||
|
|
12f3c1b77f | ||
|
|
e5710a02cb | ||
|
|
0bac5fc5e1 | ||
|
|
c7d5fc8622 | ||
|
|
f661cee847 | ||
|
|
f645ee47c8 | ||
|
|
5e18ccc60b | ||
|
|
f589fd3e10 | ||
|
|
e031fe90cf | ||
|
|
c7269f8627 | ||
|
|
dea4a61637 | ||
|
|
23bdef2571 | ||
|
|
8dea145e39 | ||
|
|
853a7692d1 | ||
|
|
7645da568c | ||
|
|
01a4dcbcee | ||
|
|
b579f6ebbf | ||
|
|
cd2f8f0e00 | ||
|
|
15a24f0898 | ||
|
|
800b01b0c8 | ||
|
|
6f42cb6e51 | ||
|
|
04b7b4bf7f | ||
|
|
c14b57c079 | ||
|
|
c903695be5 | ||
|
|
8658c759f0 | ||
|
|
021ef351c2 | ||
|
|
acdc911e4e | ||
|
|
5e86964bf4 | ||
|
|
9ac38129b6 | ||
|
|
69c76171f1 | ||
|
|
f8bc0ce267 | ||
|
|
3569c0de67 | ||
|
|
db9ff9ab5d | ||
|
|
e4eed8c6db | ||
|
|
f0e496a85a | ||
|
|
7e5503c17a | ||
|
|
0b226f60be | ||
|
|
05e59e3a9f | ||
|
|
56a8ffdb6e | ||
|
|
3d2e031d4f | ||
|
|
fad2742d53 | ||
|
|
69535d8a0a | ||
|
|
90770b746e | ||
|
|
42eba04522 | ||
|
|
eba3b7f664 | ||
|
|
ab36e6ae7b | ||
|
|
53ba95e4f0 | ||
|
|
98cb90ef86 | ||
|
|
c750d91a07 | ||
|
|
6b839ac775 | ||
|
|
651fca85c7 | ||
|
|
0c359af5c0 | ||
|
|
0b74d00693 | ||
|
|
7f2c341664 | ||
|
|
5c1ec439f0 | ||
|
|
af377e34b0 | ||
|
|
293eb9ba46 | ||
|
|
38453528c3 | ||
|
|
f566666e88 | ||
|
|
06bffe836c | ||
|
|
3ccb579516 | ||
|
|
2e0f3ecb70 | ||
|
|
59f4f9505a | ||
|
|
3d14c0f2b9 | ||
|
|
c07f11e42f | ||
|
|
e9b0b40b79 | ||
|
|
279d733dfb | ||
|
|
6304be625c | ||
|
|
7824fc80f6 | ||
|
|
bfc5786a61 | ||
|
|
d1d8a595bd | ||
|
|
7329cfab36 | ||
|
|
85be8563fe | ||
|
|
4d07253a48 | ||
|
|
309ce25189 | ||
|
|
ba8c92687d | ||
|
|
96e7a5928e | ||
|
|
0bd8d05638 | ||
|
|
71b36206be | ||
|
|
34c20ff85b | ||
|
|
8af87bd6b1 | ||
|
|
bd228fd097 | ||
|
|
bb277fd89f | ||
|
|
510d8e6056 | ||
|
|
7da341560e | ||
|
|
19916a8c89 | ||
|
|
e413ea04b7 | ||
|
|
1f2453fec6 | ||
|
|
cf1e0239ce | ||
|
|
8bc07e800c | ||
|
|
9b0e82f35e | ||
|
|
03725c5795 | ||
|
|
48608b4a4b | ||
|
|
112bed0cbe | ||
|
|
65259b5c6a | ||
|
|
cc9d725bbb | ||
|
|
ee93e327ba | ||
|
|
b771b6b5fe | ||
|
|
e021662f39 | ||
|
|
04b568b38f | ||
|
|
3b3755fe19 | ||
|
|
7a53f29c03 | ||
|
|
4671e88d7d | ||
|
|
ce59b9f292 | ||
|
|
c449271f4e | ||
|
|
7d5b8becc3 | ||
|
|
2228cd72cf | ||
|
|
a3f83feb63 | ||
|
|
73448a27a8 | ||
|
|
581f41adb3 | ||
|
|
88a4205f1c | ||
|
|
eea32afdb8 | ||
|
|
7f0c4b418e | ||
|
|
4785fe02bb | ||
|
|
923dce2b07 | ||
|
|
2c23670300 | ||
|
|
3c19b50500 | ||
|
|
d604d78e7b | ||
|
|
a755fdbe80 | ||
|
|
9cd9385db7 | ||
|
|
c8a9fe541d | ||
|
|
d85fccdfed | ||
|
|
a119812437 | ||
|
|
87fd0924e2 | ||
|
|
cdf5fdb294 | ||
|
|
b8e642f7ac | ||
|
|
2de9b7c7c8 | ||
|
|
3ad695328f | ||
|
|
8b8d829faf | ||
|
|
64be6aa3a5 | ||
|
|
1d69ef410a | ||
|
|
b3a29558ee | ||
|
|
777175b0df | ||
|
|
851c7a699a | ||
|
|
0526815c15 | ||
|
|
3cad470385 | ||
|
|
818ff25cd1 | ||
|
|
6555500bcf | ||
|
|
e015d99abb | ||
|
|
64066b9acd | ||
|
|
615ddd5342 | ||
|
|
a062006b9d | ||
|
|
3075a45592 | ||
|
|
125ffd21f9 | ||
|
|
9459b8d461 | ||
|
|
d3682c5f28 | ||
|
|
519cc559b0 | ||
|
|
728104da6c | ||
|
|
2a16dc6613 | ||
|
|
c143fa0778 | ||
|
|
b1b163efd7 | ||
|
|
1be7e21583 | ||
|
|
fa53722367 | ||
|
|
314b773abb | ||
|
|
782b4bbc16 | ||
|
|
0818ab82e7 | ||
|
|
36968af155 | ||
|
|
733b124a90 | ||
|
|
0d5a12ea04 | ||
|
|
786e05beb5 | ||
|
|
7f13b24ab6 | ||
|
|
6a950a6007 | ||
|
|
23beefed73 | ||
|
|
a0fca17251 | ||
|
|
5300be620c | ||
|
|
606efc7df4 | ||
|
|
0a15c7676b | ||
|
|
326e7da609 | ||
|
|
8813739673 | ||
|
|
58ef8a31d7 | ||
|
|
0c71114aed | ||
|
|
113cb513f7 | ||
|
|
15d9890eee | ||
|
|
0b5b06cb47 | ||
|
|
aaec1d4fb1 | ||
|
|
4b2c804767 | ||
|
|
b32aa8a6a1 | ||
|
|
d1a8d658e1 | ||
|
|
0f0044125c | ||
|
|
a63780b977 | ||
|
|
e551ccfb93 | ||
|
|
8a1962d135 | ||
|
|
69b3072d98 | ||
|
|
7a33ebfc5b | ||
|
|
e2f66064d1 | ||
|
|
ec6e63079d | ||
|
|
fd916d654d | ||
|
|
8753c1dd2c | ||
|
|
9cd063e319 | ||
|
|
44db603f69 | ||
|
|
2446ec9b56 | ||
|
|
777e7c21b7 | ||
|
|
2a52196b78 | ||
|
|
e30d10253f | ||
|
|
3c5904d2a5 | ||
|
|
844fb64a60 | ||
|
|
ee56f3f119 | ||
|
|
079ba76ae7 | ||
|
|
06ca48a40f | ||
|
|
5fe07d2e08 | ||
|
|
841c225b9e | ||
|
|
25def2c8b8 |
12
.github/CODEOWNERS
vendored
12
.github/CODEOWNERS
vendored
@@ -73,6 +73,7 @@ runtime/ftplugin/awk.vim @dkearns
|
||||
runtime/ftplugin/basic.vim @dkearns
|
||||
runtime/ftplugin/bst.vim @tpope
|
||||
runtime/ftplugin/cfg.vim @chrisbra
|
||||
runtime/ftplugin/clojure.vim @axvr
|
||||
runtime/ftplugin/csh.vim @dkearns
|
||||
runtime/ftplugin/css.vim @dkearns
|
||||
runtime/ftplugin/cucumber.vim @tpope
|
||||
@@ -88,10 +89,13 @@ runtime/ftplugin/gitsendemail.vim @tpope
|
||||
runtime/ftplugin/gprof.vim @dpelle
|
||||
runtime/ftplugin/haml.vim @tpope
|
||||
runtime/ftplugin/hgcommit.vim @k-takata
|
||||
runtime/ftplugin/i3config.vim @hiqua
|
||||
runtime/ftplugin/indent.vim @dkearns
|
||||
runtime/ftplugin/javascript.vim @dkearns
|
||||
runtime/ftplugin/javascriptreact.vim @dkearns
|
||||
runtime/ftplugin/kconfig.vim @chrisbra
|
||||
runtime/ftplugin/liquid.vim @tpope
|
||||
runtime/ftplugin/lua.vim @dkearns
|
||||
runtime/ftplugin/m3build.vim @dkearns
|
||||
runtime/ftplugin/m3quake.vim @dkearns
|
||||
runtime/ftplugin/markdown.vim @tpope
|
||||
@@ -107,9 +111,11 @@ runtime/ftplugin/pbtxt.vim @lakshayg
|
||||
runtime/ftplugin/pdf.vim @tpope
|
||||
runtime/ftplugin/ps1.vim @heaths
|
||||
runtime/ftplugin/ps1xml.vim @heaths
|
||||
runtime/ftplugin/routeros.vim @zainin
|
||||
runtime/ftplugin/ruby.vim @tpope @dkearns
|
||||
runtime/ftplugin/sass.vim @tpope
|
||||
runtime/ftplugin/scss.vim @tpope
|
||||
runtime/ftplugin/solution.vim @dkearns
|
||||
runtime/ftplugin/spec.vim @ignatenkobrain
|
||||
runtime/ftplugin/systemverilog.vim @Kocha
|
||||
runtime/ftplugin/tcsh.vim @dkearns
|
||||
@@ -122,6 +128,7 @@ runtime/ftplugin/xml.vim @chrisbra
|
||||
runtime/ftplugin/zsh.vim @chrisbra
|
||||
runtime/indent/bst.vim @tpope
|
||||
runtime/indent/cdl.vim @dkearns
|
||||
runtime/indent/clojure.vim @axvr
|
||||
runtime/indent/config.vim @dkearns
|
||||
runtime/indent/css.vim @dkearns
|
||||
runtime/indent/cucumber.vim @tpope
|
||||
@@ -169,6 +176,7 @@ runtime/plugin/vimballPlugin.vim @cecamp
|
||||
runtime/plugin/zipPlugin.vim @cecamp
|
||||
runtime/syntax/aidl.vim @dpelle
|
||||
runtime/syntax/amiga.vim @cecamp
|
||||
runtime/syntax/arduino.vim @johshoff
|
||||
runtime/syntax/asm.vim @dkearns
|
||||
runtime/syntax/asmh8300.vim @dkearns
|
||||
runtime/syntax/asterisk.vim @jaunis
|
||||
@@ -178,6 +186,7 @@ runtime/syntax/bst.vim @tpope
|
||||
runtime/syntax/cabal.vim @coot
|
||||
runtime/syntax/cabalconfig.vim @coot
|
||||
runtime/syntax/cabalproject.vim @coot
|
||||
runtime/syntax/clojure.vim @axvr
|
||||
runtime/syntax/cs.vim @nickspoons
|
||||
runtime/syntax/csh.vim @cecamp
|
||||
runtime/syntax/cucumber.vim @tpope
|
||||
@@ -201,6 +210,8 @@ runtime/syntax/groff.vim @jmarshall
|
||||
runtime/syntax/haml.vim @tpope
|
||||
runtime/syntax/haskell.vim @coot
|
||||
runtime/syntax/hgcommit.vim @k-takata
|
||||
runtime/syntax/i3config.vim @hiqua
|
||||
runtime/syntax/indent.vim @dkearns
|
||||
runtime/syntax/kconfig.vim @chrisbra
|
||||
runtime/syntax/less.vim @genoma
|
||||
runtime/syntax/lex.vim @cecamp
|
||||
@@ -229,6 +240,7 @@ runtime/syntax/ps1.vim @heaths
|
||||
runtime/syntax/ps1xml.vim @heaths
|
||||
runtime/syntax/psl.vim @danielkho
|
||||
runtime/syntax/rc.vim @chrisbra
|
||||
runtime/syntax/routeros.vim @zainin
|
||||
runtime/syntax/rpcgen.vim @cecamp
|
||||
runtime/syntax/ruby.vim @dkearns
|
||||
runtime/syntax/sass.vim @tpope
|
||||
|
||||
26
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
26
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
@@ -8,6 +8,11 @@ body:
|
||||
attributes:
|
||||
value: |
|
||||
Thanks for reporting issues of Vim!
|
||||
|
||||
If you want to report a security issue, instead of reporting it here
|
||||
you can alternatively disclose it on
|
||||
[huntr.dev](https://huntr.dev/bounties/disclose/?utm_campaign=vim%2Fvim&utm_medium=social&utm_source=github&target=https%3A%2F%2Fgithub.com%2Fvim%2Fvim).
|
||||
They have rewards in the form of money, swag and CVEs.
|
||||
|
||||
To make it easier for us to help you please enter detailed information below.
|
||||
- type: textarea
|
||||
@@ -26,18 +31,23 @@ body:
|
||||
placeholder: A clear and concise description of what you expected to happen.
|
||||
validations:
|
||||
required: true
|
||||
- type: input
|
||||
attributes:
|
||||
label: Operating system
|
||||
description: >
|
||||
Your operating system name, version and desktop environment.
|
||||
validations:
|
||||
required: true
|
||||
- type: input
|
||||
attributes:
|
||||
label: Version of Vim
|
||||
description: >
|
||||
The name of your development environment, version. [e.g. GNOME Terminal (v0.0.0000)]
|
||||
Including patch level, use ":version" to see it [e.g. 8.2.1234]
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Environment
|
||||
description: >
|
||||
OS [e.g. Ubuntu 21.10], terminal [e.g. GNOME Terminal 3.38.1], value of $TERM, shell [e.g. bash 5.1.8]; anything that might matter
|
||||
placeholder: |
|
||||
Operating system:
|
||||
Terminal:
|
||||
Value of $TERM:
|
||||
Shell:
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
|
||||
36
.github/workflows/ci.yml
vendored
36
.github/workflows/ci.yml
vendored
@@ -5,6 +5,13 @@ on:
|
||||
branches: ['**']
|
||||
pull_request:
|
||||
|
||||
# Cancels all previous workflow runs for pull requests that have not completed.
|
||||
concurrency:
|
||||
# The concurrency group contains the workflow name and the branch name for
|
||||
# pull requests or the commit hash for any other events.
|
||||
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
linux:
|
||||
runs-on: ubuntu-18.04
|
||||
@@ -75,16 +82,16 @@ jobs:
|
||||
libtool-bin \
|
||||
libsodium-dev
|
||||
|
||||
- name: Install clang-11
|
||||
- name: Install clang-13
|
||||
if: matrix.compiler == 'clang'
|
||||
run: |
|
||||
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
|
||||
. /etc/lsb-release
|
||||
sudo add-apt-repository -y "deb http://apt.llvm.org/${DISTRIB_CODENAME}/ llvm-toolchain-${DISTRIB_CODENAME}-11 main"
|
||||
sudo apt-get install -y clang-11 llvm-11
|
||||
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-11 100
|
||||
sudo update-alternatives --set clang /usr/bin/clang-11
|
||||
sudo update-alternatives --install /usr/bin/llvm-cov llvm-cov /usr/bin/llvm-cov-11 100
|
||||
sudo add-apt-repository -y "deb http://apt.llvm.org/${DISTRIB_CODENAME}/ llvm-toolchain-${DISTRIB_CODENAME}-13 main"
|
||||
sudo apt-get install -y clang-13 llvm-13
|
||||
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-13 100
|
||||
sudo update-alternatives --set clang /usr/bin/clang-13
|
||||
sudo update-alternatives --install /usr/bin/llvm-cov llvm-cov /usr/bin/llvm-cov-13 100
|
||||
|
||||
- name: Set up environment
|
||||
run: |
|
||||
@@ -188,6 +195,10 @@ jobs:
|
||||
# Append various warning flags to CFLAGS.
|
||||
sed -i -f ci/config.mk.sed ${SRCDIR}/auto/config.mk
|
||||
sed -i -f ci/config.mk.${CC}.sed ${SRCDIR}/auto/config.mk
|
||||
if [[ ${CC} = clang ]]; then
|
||||
# Suppress some warnings produced by clang 12 and later.
|
||||
sed -i -f ci/config.mk.clang-12.sed ${SRCDIR}/auto/config.mk
|
||||
fi
|
||||
|
||||
- name: Build
|
||||
if: (!contains(matrix.extra, 'unittests'))
|
||||
@@ -230,7 +241,7 @@ jobs:
|
||||
if: contains(matrix.extra, 'asan') && !cancelled()
|
||||
run: |
|
||||
for f in $(grep -lR '#[[:digit:]]* *0x[[:digit:]a-fA-F]*' "${LOG_DIR}"); do
|
||||
asan_symbolize-11 -l "$f"
|
||||
asan_symbolize-13 -l "$f"
|
||||
false # in order to fail a job
|
||||
done
|
||||
|
||||
@@ -251,7 +262,7 @@ jobs:
|
||||
runs-on: macos-latest
|
||||
|
||||
env:
|
||||
CC: ${{ matrix.compiler }}
|
||||
CC: clang
|
||||
TEST: test
|
||||
SRCDIR: ./src
|
||||
LEAK_CFLAGS: -DEXITFREE
|
||||
@@ -260,8 +271,7 @@ jobs:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
features: [tiny, huge]
|
||||
compiler: [clang, gcc]
|
||||
features: [tiny, normal, huge]
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
@@ -282,6 +292,8 @@ jobs:
|
||||
echo "TEST=testtiny"
|
||||
echo "CONFOPT=--disable-gui"
|
||||
;;
|
||||
normal)
|
||||
;;
|
||||
huge)
|
||||
echo "CONFOPT=--enable-perlinterp --enable-python3interp --enable-rubyinterp --enable-luainterp --enable-tclinterp"
|
||||
;;
|
||||
@@ -296,6 +308,10 @@ jobs:
|
||||
sed -i.bak -f ci/config.mk.sed ${SRCDIR}/auto/config.mk
|
||||
# On macOS, the entity of gcc is clang.
|
||||
sed -i.bak -f ci/config.mk.clang.sed ${SRCDIR}/auto/config.mk
|
||||
# Suppress some warnings produced by clang 12 and later.
|
||||
if clang --version | grep -qs 'Apple clang version \(1[3-9]\|[2-9]\)\.'; then
|
||||
sed -i.bak -f ci/config.mk.clang-12.sed ${SRCDIR}/auto/config.mk
|
||||
fi
|
||||
|
||||
- name: Build
|
||||
env:
|
||||
|
||||
7
.github/workflows/codeql-analysis.yml
vendored
7
.github/workflows/codeql-analysis.yml
vendored
@@ -14,6 +14,13 @@ on:
|
||||
schedule:
|
||||
- cron: '0 18 * * 1'
|
||||
|
||||
# Cancels all previous workflow runs for pull requests that have not completed.
|
||||
concurrency:
|
||||
# The concurrency group contains the workflow name and the branch name for
|
||||
# pull requests or the commit hash for any other events.
|
||||
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
analyze:
|
||||
name: Analyze
|
||||
|
||||
13
Filelist
13
Filelist
@@ -7,6 +7,8 @@ SRC_ALL = \
|
||||
.coveralls.yml \
|
||||
.gitattributes \
|
||||
.github/CODEOWNERS \
|
||||
.github/ISSUE_TEMPLATE/bug_report.yml \
|
||||
.github/ISSUE_TEMPLATE/feature_request.md \
|
||||
.github/workflows/ci.yml \
|
||||
.github/workflows/codeql-analysis.yml \
|
||||
.github/workflows/coverity.yml \
|
||||
@@ -142,7 +144,7 @@ SRC_ALL = \
|
||||
src/tag.c \
|
||||
src/term.c \
|
||||
src/terminal.c \
|
||||
src/term.h \
|
||||
src/termdefs.h \
|
||||
src/termlib.c \
|
||||
src/testing.c \
|
||||
src/textformat.c \
|
||||
@@ -158,8 +160,11 @@ SRC_ALL = \
|
||||
src/version.h \
|
||||
src/vim.h \
|
||||
src/vim9.h \
|
||||
src/vim9cmds.c \
|
||||
src/vim9compile.c \
|
||||
src/vim9execute.c \
|
||||
src/vim9expr.c \
|
||||
src/vim9instr.c \
|
||||
src/vim9script.c \
|
||||
src/vim9type.c \
|
||||
src/viminfo.c \
|
||||
@@ -317,8 +322,11 @@ SRC_ALL = \
|
||||
src/proto/usercmd.pro \
|
||||
src/proto/userfunc.pro \
|
||||
src/proto/version.pro \
|
||||
src/proto/vim9cmds.pro \
|
||||
src/proto/vim9compile.pro \
|
||||
src/proto/vim9execute.pro \
|
||||
src/proto/vim9expr.pro \
|
||||
src/proto/vim9instr.pro \
|
||||
src/proto/vim9script.pro \
|
||||
src/proto/vim9type.pro \
|
||||
src/proto/viminfo.pro \
|
||||
@@ -376,6 +384,7 @@ SRC_ALL = \
|
||||
src/libvterm/t/30state_pen.test \
|
||||
src/libvterm/t/31state_rep.test \
|
||||
src/libvterm/t/32state_flow.test \
|
||||
src/libvterm/t/40state_selection.test \
|
||||
src/libvterm/t/60screen_ascii.test \
|
||||
src/libvterm/t/61screen_unicode.test \
|
||||
src/libvterm/t/62screen_damage.test \
|
||||
@@ -798,6 +807,7 @@ RT_SCRIPTS = \
|
||||
runtime/autoload/xml/*.vim \
|
||||
runtime/colors/*.vim \
|
||||
runtime/colors/README.txt \
|
||||
runtime/colors/lists/*.vim \
|
||||
runtime/colors/tools/*.vim \
|
||||
runtime/compiler/*.vim \
|
||||
runtime/compiler/README.txt \
|
||||
@@ -850,7 +860,6 @@ RT_AMI_DOS = \
|
||||
# DOS runtime (also in the extra archive)
|
||||
RT_DOS = \
|
||||
README_dos.txt \
|
||||
runtime/rgb.txt \
|
||||
vimtutor.bat \
|
||||
|
||||
# DOS runtime without CR-LF translation (also in the extra archive)
|
||||
|
||||
@@ -26,7 +26,6 @@ src/os_win32.* Files for the Win32 port.
|
||||
src/gui_w32.* Files for the Win32 GUI.
|
||||
src/gui_w48.* Files for the Win32 and Win16 GUI.
|
||||
src/Make_mvc.mak MS Visual C++ makefile for the Win32 GUI.
|
||||
runtime/rgb.txt File with color definitions for the Win32 GUI.
|
||||
|
||||
src/if_ole.* OLE automation interface, for MS Windows 95 and NT.
|
||||
|
||||
|
||||
3
ci/config.mk.clang-12.sed
Normal file
3
ci/config.mk.clang-12.sed
Normal file
@@ -0,0 +1,3 @@
|
||||
# Clang 12 (or Apple clang 13) and later makes a warning '-Wcompound-token-split-by-macro' enable by default.
|
||||
/^PERL_CFLAGS_EXTRA[[:blank:]]*=/s/$/ -Wno-error=compound-token-split-by-macro/
|
||||
/^RUBY_CFLAGS_EXTRA[[:blank:]]*=/s/$/ -Wno-error=compound-token-split-by-macro/
|
||||
@@ -1,2 +1,2 @@
|
||||
/^CFLAGS[[:blank:]]*=/s/$/ -Wno-error=missing-field-initializers/
|
||||
/^RUBY_CFLAGS[[:blank:]]*=/s/$/ -Wno-error=unknown-attributes -Wno-error=ignored-attributes/
|
||||
/^RUBY_CFLAGS_EXTRA[[:blank:]]*=/s/$/ -Wno-error=unknown-attributes -Wno-error=ignored-attributes/
|
||||
|
||||
@@ -1,2 +1,3 @@
|
||||
/^CFLAGS[[:blank:]]*=/s/$/ -Wall -Wextra -Wshadow -Werror/
|
||||
/^PERL_CFLAGS[[:blank:]]*=/s/$/ -Wno-error=unused-function/
|
||||
/^PERL_CFLAGS_EXTRA[[:blank:]]*=/s/$/ -Wno-error=unused-function/
|
||||
/^RUBY_CFLAGS_EXTRA[[:blank:]]*=/s/$/ -Wno-error=unused-parameter/
|
||||
|
||||
@@ -357,7 +357,6 @@ Section "$(str_section_exe)" id_section_exe
|
||||
File ..\README.txt
|
||||
File ..\uninstall.txt
|
||||
File ${VIMRT}\*.vim
|
||||
File ${VIMRT}\rgb.txt
|
||||
|
||||
File ${VIMTOOLS}\diff.exe
|
||||
File ${VIMTOOLS}\winpty${BIT}.dll
|
||||
@@ -367,6 +366,8 @@ Section "$(str_section_exe)" id_section_exe
|
||||
File ${VIMRT}\colors\*.*
|
||||
SetOutPath $0\colors\tools
|
||||
File ${VIMRT}\colors\tools\*.*
|
||||
SetOutPath $0\colors\lists
|
||||
File ${VIMRT}\colors\lists\*.*
|
||||
|
||||
SetOutPath $0\compiler
|
||||
File ${VIMRT}\compiler\*.*
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
40
runtime/autoload/dist/ft.vim
vendored
40
runtime/autoload/dist/ft.vim
vendored
@@ -1,7 +1,7 @@
|
||||
" Vim functions for file type detection
|
||||
"
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2020 Aug 17
|
||||
" Last Change: 2021 Dec 17
|
||||
|
||||
" These functions are moved here from runtime/filetype.vim to make startup
|
||||
" faster.
|
||||
@@ -219,6 +219,23 @@ func dist#ft#FTe()
|
||||
endif
|
||||
endfunc
|
||||
|
||||
" Distinguish between Forth and F#.
|
||||
" Provided by Doug Kearns.
|
||||
func dist#ft#FTfs()
|
||||
if exists("g:filetype_fs")
|
||||
exe "setf " . g:filetype_fs
|
||||
else
|
||||
let line = getline(nextnonblank(1))
|
||||
" comments and colon definitions
|
||||
if line =~ '^\s*\.\=( ' || line =~ '^\s*\\G\= ' || line =~ '^\\$'
|
||||
\ || line =~ '^\s*: \S'
|
||||
setf forth
|
||||
else
|
||||
setf fsharp
|
||||
endif
|
||||
endif
|
||||
endfunc
|
||||
|
||||
" Distinguish between HTML, XHTML and Django
|
||||
func dist#ft#FThtml()
|
||||
let n = 1
|
||||
@@ -272,6 +289,8 @@ func dist#ft#FTm()
|
||||
" excluding end(for|function|if|switch|while) common to Murphi
|
||||
let octave_block_terminators = '\<end\%(_try_catch\|classdef\|enumeration\|events\|methods\|parfor\|properties\)\>'
|
||||
|
||||
let objc_preprocessor = '^\s*#\s*\%(import\|include\|define\|if\|ifn\=def\|undef\|line\|error\|pragma\)\>'
|
||||
|
||||
let n = 1
|
||||
let saw_comment = 0 " Whether we've seen a multiline comment leader.
|
||||
while n < 100
|
||||
@@ -282,7 +301,7 @@ func dist#ft#FTm()
|
||||
" anything more definitive.
|
||||
let saw_comment = 1
|
||||
endif
|
||||
if line =~ '^\s*\(#\s*\(include\|import\)\>\|@import\>\|//\)'
|
||||
if line =~ '^\s*//' || line =~ '^\s*@import\>' || line =~ objc_preprocessor
|
||||
setf objc
|
||||
return
|
||||
endif
|
||||
@@ -792,6 +811,23 @@ func dist#ft#Redif()
|
||||
endwhile
|
||||
endfunc
|
||||
|
||||
" This function is called for all files under */debian/patches/*, make sure not
|
||||
" to non-dep3patch files, such as README and other text files.
|
||||
func dist#ft#Dep3patch()
|
||||
if expand('%:t') ==# 'series'
|
||||
return
|
||||
endif
|
||||
|
||||
for ln in getline(1, 100)
|
||||
if ln =~# '^\%(Description\|Subject\|Origin\|Bug\|Forwarded\|Author\|From\|Reviewed-by\|Acked-by\|Last-Updated\|Applied-Upstream\):'
|
||||
setf dep3patch
|
||||
return
|
||||
elseif ln =~# '^---'
|
||||
" end of headers found. stop processing
|
||||
return
|
||||
endif
|
||||
endfor
|
||||
endfunc
|
||||
|
||||
" Restore 'cpoptions'
|
||||
let &cpo = s:cpo_save
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" zip.vim: Handles browsing zipfiles
|
||||
" AUTOLOAD PORTION
|
||||
" Date: Jan 07, 2020
|
||||
" Version: 31
|
||||
" Date: Nov 08, 2021
|
||||
" Version: 32
|
||||
" Maintainer: Charles E Campbell <NcampObell@SdrPchip.AorgM-NOSPAM>
|
||||
" License: Vim License (see vim's :help license)
|
||||
" Copyright: Copyright (C) 2005-2019 Charles E. Campbell {{{1
|
||||
@@ -20,7 +20,7 @@
|
||||
if &cp || exists("g:loaded_zip")
|
||||
finish
|
||||
endif
|
||||
let g:loaded_zip= "v31"
|
||||
let g:loaded_zip= "v32"
|
||||
if v:version < 702
|
||||
echohl WarningMsg
|
||||
echo "***warning*** this version of zip needs vim 7.2 or later"
|
||||
@@ -115,7 +115,13 @@ fun! zip#Browse(zipfile)
|
||||
setlocal bufhidden=hide
|
||||
setlocal nobuflisted
|
||||
setlocal nowrap
|
||||
set ft=tar
|
||||
|
||||
" Oct 12, 2021: need to re-use Bram's syntax/tar.vim.
|
||||
" Setting the filetype to zip doesn't do anything (currently),
|
||||
" but it is perhaps less confusing to curious perusers who do
|
||||
" a :echo &ft
|
||||
setf zip
|
||||
run! syntax/tar.vim
|
||||
|
||||
" give header
|
||||
call append(0, ['" zip.vim version '.g:loaded_zip,
|
||||
@@ -187,8 +193,8 @@ fun! s:ZipBrowseSelect()
|
||||
wincmd _
|
||||
endif
|
||||
let s:zipfile_{winnr()}= curfile
|
||||
" call Decho("exe e ".fnameescape("zipfile:".zipfile.'::'.fname))
|
||||
exe "noswapfile e ".fnameescape("zipfile:".zipfile.'::'.fname)
|
||||
" call Decho("exe e ".fnameescape("zipfile://".zipfile.'::'.fname))
|
||||
exe "noswapfile e ".fnameescape("zipfile://".zipfile.'::'.fname)
|
||||
filetype detect
|
||||
|
||||
let &report= repkeep
|
||||
@@ -203,11 +209,11 @@ fun! zip#Read(fname,mode)
|
||||
set report=10
|
||||
|
||||
if has("unix")
|
||||
let zipfile = substitute(a:fname,'zipfile:\(.\{-}\)::[^\\].*$','\1','')
|
||||
let fname = substitute(a:fname,'zipfile:.\{-}::\([^\\].*\)$','\1','')
|
||||
let zipfile = substitute(a:fname,'zipfile://\(.\{-}\)::[^\\].*$','\1','')
|
||||
let fname = substitute(a:fname,'zipfile://.\{-}::\([^\\].*\)$','\1','')
|
||||
else
|
||||
let zipfile = substitute(a:fname,'^.\{-}zipfile:\(.\{-}\)::[^\\].*$','\1','')
|
||||
let fname = substitute(a:fname,'^.\{-}zipfile:.\{-}::\([^\\].*\)$','\1','')
|
||||
let zipfile = substitute(a:fname,'^.\{-}zipfile://\(.\{-}\)::[^\\].*$','\1','')
|
||||
let fname = substitute(a:fname,'^.\{-}zipfile://.\{-}::\([^\\].*\)$','\1','')
|
||||
let fname = substitute(fname, '[', '[[]', 'g')
|
||||
endif
|
||||
" call Decho("zipfile<".zipfile.">")
|
||||
@@ -224,7 +230,7 @@ fun! zip#Read(fname,mode)
|
||||
|
||||
" the following code does much the same thing as
|
||||
" exe "keepj sil! r! ".g:zip_unzipcmd." -p -- ".s:Escape(zipfile,1)." ".s:Escape(fnameescape(fname),1)
|
||||
" but allows zipfile:... entries in quickfix lists
|
||||
" but allows zipfile://... entries in quickfix lists
|
||||
let temp = tempname()
|
||||
" call Decho("using temp file<".temp.">")
|
||||
let fn = expand('%:p')
|
||||
@@ -296,11 +302,11 @@ fun! zip#Write(fname)
|
||||
" call Decho("current directory now: ".getcwd())
|
||||
|
||||
if has("unix")
|
||||
let zipfile = substitute(a:fname,'zipfile:\(.\{-}\)::[^\\].*$','\1','')
|
||||
let fname = substitute(a:fname,'zipfile:.\{-}::\([^\\].*\)$','\1','')
|
||||
let zipfile = substitute(a:fname,'zipfile://\(.\{-}\)::[^\\].*$','\1','')
|
||||
let fname = substitute(a:fname,'zipfile://.\{-}::\([^\\].*\)$','\1','')
|
||||
else
|
||||
let zipfile = substitute(a:fname,'^.\{-}zipfile:\(.\{-}\)::[^\\].*$','\1','')
|
||||
let fname = substitute(a:fname,'^.\{-}zipfile:.\{-}::\([^\\].*\)$','\1','')
|
||||
let zipfile = substitute(a:fname,'^.\{-}zipfile://\(.\{-}\)::[^\\].*$','\1','')
|
||||
let fname = substitute(a:fname,'^.\{-}zipfile://.\{-}::\([^\\].*\)$','\1','')
|
||||
endif
|
||||
" call Decho("zipfile<".zipfile.">")
|
||||
" call Decho("fname <".fname.">")
|
||||
|
||||
@@ -87,4 +87,5 @@ please check the following items:
|
||||
- In the GUI, is it easy to find the cursor, also in a file with lots of
|
||||
syntax highlighting?
|
||||
- Do not use hard coded escape sequences, these will not work in other
|
||||
terminals. Always use color names or #RRGGBB for the GUI.
|
||||
terminals. Always use color names or #RRGGBB for the GUI. See v:colornames
|
||||
for details on how to define your own color names.
|
||||
|
||||
166
runtime/colors/lists/csscolors.vim
Normal file
166
runtime/colors/lists/csscolors.vim
Normal file
@@ -0,0 +1,166 @@
|
||||
" Maintainer: Drew Vogel <dvogel@sidejump.org>
|
||||
" Last Change: 2021 Jul 25
|
||||
|
||||
" Similar in spirit to rgb.txt, this plugin establishes a human-friendly name
|
||||
" for every color listed in the CSS standard:
|
||||
"
|
||||
" https://www.w3.org/TR/css-color-3/
|
||||
|
||||
let s:keepcpo= &cpo
|
||||
set cpo&vim
|
||||
|
||||
call extend(v:colornames, {
|
||||
\ 'css_black': '#000000',
|
||||
\ 'css_silver': '#c0c0c0',
|
||||
\ 'css_gray': '#808080',
|
||||
\ 'css_white': '#FFFFFF',
|
||||
\ 'css_maroon': '#800000',
|
||||
\ 'css_red': '#FF0000',
|
||||
\ 'css_purple': '#800080',
|
||||
\ 'css_fuchsia': '#FF00FF',
|
||||
\ 'css_green': '#008000',
|
||||
\ 'css_lime': '#00FF00',
|
||||
\ 'css_olive': '#808000',
|
||||
\ 'css_yellow': '#FFFF00',
|
||||
\ 'css_navy': '#000080',
|
||||
\ 'css_blue': '#0000FF',
|
||||
\ 'css_teal': '#008080',
|
||||
\ 'css_aqua': '#00FFFF',
|
||||
\
|
||||
\ 'css_aliceblue': '#f0f8ff',
|
||||
\ 'css_antiquewhite': '#faebd7',
|
||||
\ 'css_aquamarine': '#7fffd4',
|
||||
\ 'css_azure': '#f0ffff',
|
||||
\ 'css_beige': '#f5f5dc',
|
||||
\ 'css_bisque': '#ffe4c4',
|
||||
\ 'css_blanchedalmond': '#ffebcd',
|
||||
\ 'css_blueviolet': '#8a2be2',
|
||||
\ 'css_brown': '#a52a2a',
|
||||
\ 'css_burlywood': '#deb887',
|
||||
\ 'css_cadetblue': '#5f9ea0',
|
||||
\ 'css_chartreuse': '#7fff00',
|
||||
\ 'css_chocolate': '#d2691e',
|
||||
\ 'css_coral': '#ff7f50',
|
||||
\ 'css_cornflowerblue': '#6495ed',
|
||||
\ 'css_cornsilk': '#fff8dc',
|
||||
\ 'css_crimson': '#dc143c',
|
||||
\ 'css_cyan': '#00ffff',
|
||||
\ 'css_darkblue': '#00008b',
|
||||
\ 'css_darkcyan': '#008b8b',
|
||||
\ 'css_darkgoldenrod': '#b8860b',
|
||||
\ 'css_darkgray': '#a9a9a9',
|
||||
\ 'css_darkgreen': '#006400',
|
||||
\ 'css_darkgrey': '#a9a9a9',
|
||||
\ 'css_darkkhaki': '#bdb76b',
|
||||
\ 'css_darkmagenta': '#8b008b',
|
||||
\ 'css_darkolivegreen': '#556b2f',
|
||||
\ 'css_darkorange': '#ff8c00',
|
||||
\ 'css_darkorchid': '#9932cc',
|
||||
\ 'css_darkred': '#8b0000',
|
||||
\ 'css_darksalmon': '#e9967a',
|
||||
\ 'css_darkseagreen': '#8fbc8f',
|
||||
\ 'css_darkslateblue': '#483d8b',
|
||||
\ 'css_darkslategray': '#2f4f4f',
|
||||
\ 'css_darkslategrey': '#2f4f4f',
|
||||
\ 'css_darkturquoise': '#00ced1',
|
||||
\ 'css_darkviolet': '#9400d3',
|
||||
\ 'css_deeppink': '#ff1493',
|
||||
\ 'css_deepskyblue': '#00bfff',
|
||||
\ 'css_dimgray': '#696969',
|
||||
\ 'css_dimgrey': '#696969',
|
||||
\ 'css_dodgerblue': '#1e90ff',
|
||||
\ 'css_firebrick': '#b22222',
|
||||
\ 'css_floralwhite': '#fffaf0',
|
||||
\ 'css_forestgreen': '#228b22',
|
||||
\ 'css_gainsboro': '#dcdcdc',
|
||||
\ 'css_ghostwhite': '#f8f8ff',
|
||||
\ 'css_gold': '#ffd700',
|
||||
\ 'css_goldenrod': '#daa520',
|
||||
\ 'css_greenyellow': '#adff2f',
|
||||
\ 'css_grey': '#808080',
|
||||
\ 'css_honeydew': '#f0fff0',
|
||||
\ 'css_hotpink': '#ff69b4',
|
||||
\ 'css_indianred': '#cd5c5c',
|
||||
\ 'css_indigo': '#4b0082',
|
||||
\ 'css_ivory': '#fffff0',
|
||||
\ 'css_khaki': '#f0e68c',
|
||||
\ 'css_lavender': '#e6e6fa',
|
||||
\ 'css_lavenderblush': '#fff0f5',
|
||||
\ 'css_lawngreen': '#7cfc00',
|
||||
\ 'css_lemonchiffon': '#fffacd',
|
||||
\ 'css_lightblue': '#add8e6',
|
||||
\ 'css_lightcoral': '#f08080',
|
||||
\ 'css_lightcyan': '#e0ffff',
|
||||
\ 'css_lightgoldenrodyellow': '#fafad2',
|
||||
\ 'css_lightgray': '#d3d3d3',
|
||||
\ 'css_lightgreen': '#90ee90',
|
||||
\ 'css_lightgrey': '#d3d3d3',
|
||||
\ 'css_lightpink': '#ffb6c1',
|
||||
\ 'css_lightsalmon': '#ffa07a',
|
||||
\ 'css_lightseagreen': '#20b2aa',
|
||||
\ 'css_lightskyblue': '#87cefa',
|
||||
\ 'css_lightslategray': '#778899',
|
||||
\ 'css_lightslategrey': '#778899',
|
||||
\ 'css_lightsteelblue': '#b0c4de',
|
||||
\ 'css_lightyellow': '#ffffe0',
|
||||
\ 'css_limegreen': '#32cd32',
|
||||
\ 'css_linen': '#faf0e6',
|
||||
\ 'css_magenta': '#ff00ff',
|
||||
\ 'css_mediumaquamarine': '#66cdaa',
|
||||
\ 'css_mediumblue': '#0000cd',
|
||||
\ 'css_mediumorchid': '#ba55d3',
|
||||
\ 'css_mediumpurple': '#9370db',
|
||||
\ 'css_mediumseagreen': '#3cb371',
|
||||
\ 'css_mediumslateblue': '#7b68ee',
|
||||
\ 'css_mediumspringgreen': '#00fa9a',
|
||||
\ 'css_mediumturquoise': '#48d1cc',
|
||||
\ 'css_mediumvioletred': '#c71585',
|
||||
\ 'css_midnightblue': '#191970',
|
||||
\ 'css_mintcream': '#f5fffa',
|
||||
\ 'css_mistyrose': '#ffe4e1',
|
||||
\ 'css_moccasin': '#ffe4b5',
|
||||
\ 'css_navajowhite': '#ffdead',
|
||||
\ 'css_oldlace': '#fdf5e6',
|
||||
\ 'css_olivedrab': '#6b8e23',
|
||||
\ 'css_orange': '#ffa500',
|
||||
\ 'css_orangered': '#ff4500',
|
||||
\ 'css_orchid': '#da70d6',
|
||||
\ 'css_palegoldenrod': '#eee8aa',
|
||||
\ 'css_palegreen': '#98fb98',
|
||||
\ 'css_paleturquoise': '#afeeee',
|
||||
\ 'css_palevioletred': '#db7093',
|
||||
\ 'css_papayawhip': '#ffefd5',
|
||||
\ 'css_peachpuff': '#ffdab9',
|
||||
\ 'css_peru': '#cd853f',
|
||||
\ 'css_pink': '#ffc0cb',
|
||||
\ 'css_plum': '#dda0dd',
|
||||
\ 'css_powderblue': '#b0e0e6',
|
||||
\ 'css_rosybrown': '#bc8f8f',
|
||||
\ 'css_royalblue': '#4169e1',
|
||||
\ 'css_saddlebrown': '#8b4513',
|
||||
\ 'css_salmon': '#fa8072',
|
||||
\ 'css_sandybrown': '#f4a460',
|
||||
\ 'css_seagreen': '#2e8b57',
|
||||
\ 'css_seashell': '#fff5ee',
|
||||
\ 'css_sienna': '#a0522d',
|
||||
\ 'css_skyblue': '#87ceeb',
|
||||
\ 'css_slateblue': '#6a5acd',
|
||||
\ 'css_slategray': '#708090',
|
||||
\ 'css_slategrey': '#708090',
|
||||
\ 'css_snow': '#fffafa',
|
||||
\ 'css_springgreen': '#00ff7f',
|
||||
\ 'css_steelblue': '#4682b4',
|
||||
\ 'css_tan': '#d2b48c',
|
||||
\ 'css_thistle': '#d8bfd8',
|
||||
\ 'css_tomato': '#ff6347',
|
||||
\ 'css_turquoise': '#40e0d0',
|
||||
\ 'css_violet': '#ee82ee',
|
||||
\ 'css_wheat': '#f5deb3',
|
||||
\ 'css_whitesmoke': '#f5f5f5',
|
||||
\ 'css_yellowgreen': '#9acd32',
|
||||
\ }, 'keep')
|
||||
|
||||
let &cpo= s:keepcpo
|
||||
unlet s:keepcpo
|
||||
|
||||
"vim: sw=4
|
||||
801
runtime/colors/lists/default.vim
Normal file
801
runtime/colors/lists/default.vim
Normal file
@@ -0,0 +1,801 @@
|
||||
" Maintainer: Drew Vogel <dvogel@sidejump.org>
|
||||
" Last Change: 2021 Jul 25
|
||||
"
|
||||
" Replaced rgb.txt as the source of de facto standard color names. This is
|
||||
" sourced each time the colorscheme command is run. It is also sourced each
|
||||
" time the highlight command fails to recognize a gui color. You can override
|
||||
" these colors by introducing a new colors/lists/default.vim file earlier in
|
||||
" the runtimepath.
|
||||
|
||||
let s:keepcpo= &cpo
|
||||
set cpo&vim
|
||||
|
||||
call extend(v:colornames, {
|
||||
\ 'snow': '#fffafa',
|
||||
\ 'ghost white': '#f8f8ff',
|
||||
\ 'ghostwhite': '#f8f8ff',
|
||||
\ 'white smoke': '#f5f5f5',
|
||||
\ 'whitesmoke': '#f5f5f5',
|
||||
\ 'gainsboro': '#dcdcdc',
|
||||
\ 'floral white': '#fffaf0',
|
||||
\ 'floralwhite': '#fffaf0',
|
||||
\ 'old lace': '#fdf5e6',
|
||||
\ 'oldlace': '#fdf5e6',
|
||||
\ 'linen': '#faf0e6',
|
||||
\ 'antique white': '#faebd7',
|
||||
\ 'antiquewhite': '#faebd7',
|
||||
\ 'papaya whip': '#ffefd5',
|
||||
\ 'papayawhip': '#ffefd5',
|
||||
\ 'blanched almond': '#ffebcd',
|
||||
\ 'blanchedalmond': '#ffebcd',
|
||||
\ 'bisque': '#ffe4c4',
|
||||
\ 'peach puff': '#ffdab9',
|
||||
\ 'peachpuff': '#ffdab9',
|
||||
\ 'navajo white': '#ffdead',
|
||||
\ 'navajowhite': '#ffdead',
|
||||
\ 'moccasin': '#ffe4b5',
|
||||
\ 'cornsilk': '#fff8dc',
|
||||
\ 'ivory': '#fffff0',
|
||||
\ 'lemon chiffon': '#fffacd',
|
||||
\ 'lemonchiffon': '#fffacd',
|
||||
\ 'seashell': '#fff5ee',
|
||||
\ 'honeydew': '#f0fff0',
|
||||
\ 'mint cream': '#f5fffa',
|
||||
\ 'mintcream': '#f5fffa',
|
||||
\ 'azure': '#f0ffff',
|
||||
\ 'alice blue': '#f0f8ff',
|
||||
\ 'aliceblue': '#f0f8ff',
|
||||
\ 'lavender': '#e6e6fa',
|
||||
\ 'lavender blush': '#fff0f5',
|
||||
\ 'lavenderblush': '#fff0f5',
|
||||
\ 'misty rose': '#ffe4e1',
|
||||
\ 'mistyrose': '#ffe4e1',
|
||||
\ 'white': '#ffffff',
|
||||
\ 'black': '#000000',
|
||||
\ 'dark slate gray': '#2f4f4f',
|
||||
\ 'darkslategray': '#2f4f4f',
|
||||
\ 'dark slate grey': '#2f4f4f',
|
||||
\ 'darkslategrey': '#2f4f4f',
|
||||
\ 'dim gray': '#696969',
|
||||
\ 'dimgray': '#696969',
|
||||
\ 'dim grey': '#696969',
|
||||
\ 'dimgrey': '#696969',
|
||||
\ 'slate gray': '#708090',
|
||||
\ 'slategray': '#708090',
|
||||
\ 'slate grey': '#708090',
|
||||
\ 'slategrey': '#708090',
|
||||
\ 'light slate gray': '#778899',
|
||||
\ 'lightslategray': '#778899',
|
||||
\ 'light slate grey': '#778899',
|
||||
\ 'lightslategrey': '#778899',
|
||||
\ 'gray': '#bebebe',
|
||||
\ 'grey': '#bebebe',
|
||||
\ 'x11 gray': '#bebebe',
|
||||
\ 'x11gray': '#bebebe',
|
||||
\ 'x11 grey': '#bebebe',
|
||||
\ 'x11grey': '#bebebe',
|
||||
\ 'web gray': '#808080',
|
||||
\ 'webgray': '#808080',
|
||||
\ 'web grey': '#808080',
|
||||
\ 'webgrey': '#808080',
|
||||
\ 'light grey': '#d3d3d3',
|
||||
\ 'lightgrey': '#d3d3d3',
|
||||
\ 'light gray': '#d3d3d3',
|
||||
\ 'lightgray': '#d3d3d3',
|
||||
\ 'midnight blue': '#191970',
|
||||
\ 'midnightblue': '#191970',
|
||||
\ 'navy': '#000080',
|
||||
\ 'navy blue': '#000080',
|
||||
\ 'navyblue': '#000080',
|
||||
\ 'cornflower blue': '#6495ed',
|
||||
\ 'cornflowerblue': '#6495ed',
|
||||
\ 'dark slate blue': '#483d8b',
|
||||
\ 'darkslateblue': '#483d8b',
|
||||
\ 'slate blue': '#6a5acd',
|
||||
\ 'slateblue': '#6a5acd',
|
||||
\ 'medium slate blue': '#7b68ee',
|
||||
\ 'mediumslateblue': '#7b68ee',
|
||||
\ 'light slate blue': '#8470ff',
|
||||
\ 'lightslateblue': '#8470ff',
|
||||
\ 'medium blue': '#0000cd',
|
||||
\ 'mediumblue': '#0000cd',
|
||||
\ 'royal blue': '#4169e1',
|
||||
\ 'royalblue': '#4169e1',
|
||||
\ 'blue': '#0000ff',
|
||||
\ 'dodger blue': '#1e90ff',
|
||||
\ 'dodgerblue': '#1e90ff',
|
||||
\ 'deep sky blue': '#00bfff',
|
||||
\ 'deepskyblue': '#00bfff',
|
||||
\ 'sky blue': '#87ceeb',
|
||||
\ 'skyblue': '#87ceeb',
|
||||
\ 'light sky blue': '#87cefa',
|
||||
\ 'lightskyblue': '#87cefa',
|
||||
\ 'steel blue': '#4682b4',
|
||||
\ 'steelblue': '#4682b4',
|
||||
\ 'light steel blue': '#b0c4de',
|
||||
\ 'lightsteelblue': '#b0c4de',
|
||||
\ 'light blue': '#add8e6',
|
||||
\ 'lightblue': '#add8e6',
|
||||
\ 'powder blue': '#b0e0e6',
|
||||
\ 'powderblue': '#b0e0e6',
|
||||
\ 'pale turquoise': '#afeeee',
|
||||
\ 'paleturquoise': '#afeeee',
|
||||
\ 'dark turquoise': '#00ced1',
|
||||
\ 'darkturquoise': '#00ced1',
|
||||
\ 'medium turquoise': '#48d1cc',
|
||||
\ 'mediumturquoise': '#48d1cc',
|
||||
\ 'turquoise': '#40e0d0',
|
||||
\ 'cyan': '#00ffff',
|
||||
\ 'aqua': '#00ffff',
|
||||
\ 'light cyan': '#e0ffff',
|
||||
\ 'lightcyan': '#e0ffff',
|
||||
\ 'cadet blue': '#5f9ea0',
|
||||
\ 'cadetblue': '#5f9ea0',
|
||||
\ 'medium aquamarine': '#66cdaa',
|
||||
\ 'mediumaquamarine': '#66cdaa',
|
||||
\ 'aquamarine': '#7fffd4',
|
||||
\ 'dark green': '#006400',
|
||||
\ 'darkgreen': '#006400',
|
||||
\ 'dark olive green': '#556b2f',
|
||||
\ 'darkolivegreen': '#556b2f',
|
||||
\ 'dark sea green': '#8fbc8f',
|
||||
\ 'darkseagreen': '#8fbc8f',
|
||||
\ 'sea green': '#2e8b57',
|
||||
\ 'seagreen': '#2e8b57',
|
||||
\ 'medium sea green': '#3cb371',
|
||||
\ 'mediumseagreen': '#3cb371',
|
||||
\ 'light sea green': '#20b2aa',
|
||||
\ 'lightseagreen': '#20b2aa',
|
||||
\ 'pale green': '#98fb98',
|
||||
\ 'palegreen': '#98fb98',
|
||||
\ 'spring green': '#00ff7f',
|
||||
\ 'springgreen': '#00ff7f',
|
||||
\ 'lawn green': '#7cfc00',
|
||||
\ 'lawngreen': '#7cfc00',
|
||||
\ 'green': '#00ff00',
|
||||
\ 'lime': '#00ff00',
|
||||
\ 'x11 green': '#00ff00',
|
||||
\ 'x11green': '#00ff00',
|
||||
\ 'web green': '#008000',
|
||||
\ 'webgreen': '#008000',
|
||||
\ 'chartreuse': '#7fff00',
|
||||
\ 'medium spring green': '#00fa9a',
|
||||
\ 'mediumspringgreen': '#00fa9a',
|
||||
\ 'green yellow': '#adff2f',
|
||||
\ 'greenyellow': '#adff2f',
|
||||
\ 'lime green': '#32cd32',
|
||||
\ 'limegreen': '#32cd32',
|
||||
\ 'yellow green': '#9acd32',
|
||||
\ 'yellowgreen': '#9acd32',
|
||||
\ 'forest green': '#228b22',
|
||||
\ 'forestgreen': '#228b22',
|
||||
\ 'olive drab': '#6b8e23',
|
||||
\ 'olivedrab': '#6b8e23',
|
||||
\ 'dark khaki': '#bdb76b',
|
||||
\ 'darkkhaki': '#bdb76b',
|
||||
\ 'khaki': '#f0e68c',
|
||||
\ 'pale goldenrod': '#eee8aa',
|
||||
\ 'palegoldenrod': '#eee8aa',
|
||||
\ 'light goldenrod yellow': '#fafad2',
|
||||
\ 'lightgoldenrodyellow': '#fafad2',
|
||||
\ 'light yellow': '#ffffe0',
|
||||
\ 'lightyellow': '#ffffe0',
|
||||
\ 'yellow': '#ffff00',
|
||||
\ 'gold': '#ffd700',
|
||||
\ 'light goldenrod': '#eedd82',
|
||||
\ 'lightgoldenrod': '#eedd82',
|
||||
\ 'goldenrod': '#daa520',
|
||||
\ 'dark goldenrod': '#b8860b',
|
||||
\ 'darkgoldenrod': '#b8860b',
|
||||
\ 'rosy brown': '#bc8f8f',
|
||||
\ 'rosybrown': '#bc8f8f',
|
||||
\ 'indian red': '#cd5c5c',
|
||||
\ 'indianred': '#cd5c5c',
|
||||
\ 'saddle brown': '#8b4513',
|
||||
\ 'saddlebrown': '#8b4513',
|
||||
\ 'sienna': '#a0522d',
|
||||
\ 'peru': '#cd853f',
|
||||
\ 'burlywood': '#deb887',
|
||||
\ 'beige': '#f5f5dc',
|
||||
\ 'wheat': '#f5deb3',
|
||||
\ 'sandy brown': '#f4a460',
|
||||
\ 'sandybrown': '#f4a460',
|
||||
\ 'tan': '#d2b48c',
|
||||
\ 'chocolate': '#d2691e',
|
||||
\ 'firebrick': '#b22222',
|
||||
\ 'brown': '#a52a2a',
|
||||
\ 'dark salmon': '#e9967a',
|
||||
\ 'darksalmon': '#e9967a',
|
||||
\ 'salmon': '#fa8072',
|
||||
\ 'light salmon': '#ffa07a',
|
||||
\ 'lightsalmon': '#ffa07a',
|
||||
\ 'orange': '#ffa500',
|
||||
\ 'dark orange': '#ff8c00',
|
||||
\ 'darkorange': '#ff8c00',
|
||||
\ 'coral': '#ff7f50',
|
||||
\ 'light coral': '#f08080',
|
||||
\ 'lightcoral': '#f08080',
|
||||
\ 'tomato': '#ff6347',
|
||||
\ 'orange red': '#ff4500',
|
||||
\ 'orangered': '#ff4500',
|
||||
\ 'red': '#ff0000',
|
||||
\ 'hot pink': '#ff69b4',
|
||||
\ 'hotpink': '#ff69b4',
|
||||
\ 'deep pink': '#ff1493',
|
||||
\ 'deeppink': '#ff1493',
|
||||
\ 'pink': '#ffc0cb',
|
||||
\ 'light pink': '#ffb6c1',
|
||||
\ 'lightpink': '#ffb6c1',
|
||||
\ 'pale violet red': '#db7093',
|
||||
\ 'palevioletred': '#db7093',
|
||||
\ 'maroon': '#b03060',
|
||||
\ 'x11 maroon': '#b03060',
|
||||
\ 'x11maroon': '#b03060',
|
||||
\ 'web maroon': '#800000',
|
||||
\ 'webmaroon': '#800000',
|
||||
\ 'medium violet red': '#c71585',
|
||||
\ 'mediumvioletred': '#c71585',
|
||||
\ 'violet red': '#d02090',
|
||||
\ 'violetred': '#d02090',
|
||||
\ 'magenta': '#ff00ff',
|
||||
\ 'fuchsia': '#ff00ff',
|
||||
\ 'violet': '#ee82ee',
|
||||
\ 'plum': '#dda0dd',
|
||||
\ 'orchid': '#da70d6',
|
||||
\ 'medium orchid': '#ba55d3',
|
||||
\ 'mediumorchid': '#ba55d3',
|
||||
\ 'dark orchid': '#9932cc',
|
||||
\ 'darkorchid': '#9932cc',
|
||||
\ 'dark violet': '#9400d3',
|
||||
\ 'darkviolet': '#9400d3',
|
||||
\ 'blue violet': '#8a2be2',
|
||||
\ 'blueviolet': '#8a2be2',
|
||||
\ 'purple': '#a020f0',
|
||||
\ 'x11 purple': '#a020f0',
|
||||
\ 'x11purple': '#a020f0',
|
||||
\ 'web purple': '#800080',
|
||||
\ 'webpurple': '#800080',
|
||||
\ 'medium purple': '#9370db',
|
||||
\ 'mediumpurple': '#9370db',
|
||||
\ 'thistle': '#d8bfd8',
|
||||
\ 'snow1': '#fffafa',
|
||||
\ 'snow2': '#eee9e9',
|
||||
\ 'snow3': '#cdc9c9',
|
||||
\ 'snow4': '#8b8989',
|
||||
\ 'seashell1': '#fff5ee',
|
||||
\ 'seashell2': '#eee5de',
|
||||
\ 'seashell3': '#cdc5bf',
|
||||
\ 'seashell4': '#8b8682',
|
||||
\ 'antiquewhite1': '#ffefdb',
|
||||
\ 'antiquewhite2': '#eedfcc',
|
||||
\ 'antiquewhite3': '#cdc0b0',
|
||||
\ 'antiquewhite4': '#8b8378',
|
||||
\ 'bisque1': '#ffe4c4',
|
||||
\ 'bisque2': '#eed5b7',
|
||||
\ 'bisque3': '#cdb79e',
|
||||
\ 'bisque4': '#8b7d6b',
|
||||
\ 'peachpuff1': '#ffdab9',
|
||||
\ 'peachpuff2': '#eecbad',
|
||||
\ 'peachpuff3': '#cdaf95',
|
||||
\ 'peachpuff4': '#8b7765',
|
||||
\ 'navajowhite1': '#ffdead',
|
||||
\ 'navajowhite2': '#eecfa1',
|
||||
\ 'navajowhite3': '#cdb38b',
|
||||
\ 'navajowhite4': '#8b795e',
|
||||
\ 'lemonchiffon1': '#fffacd',
|
||||
\ 'lemonchiffon2': '#eee9bf',
|
||||
\ 'lemonchiffon3': '#cdc9a5',
|
||||
\ 'lemonchiffon4': '#8b8970',
|
||||
\ 'cornsilk1': '#fff8dc',
|
||||
\ 'cornsilk2': '#eee8cd',
|
||||
\ 'cornsilk3': '#cdc8b1',
|
||||
\ 'cornsilk4': '#8b8878',
|
||||
\ 'ivory1': '#fffff0',
|
||||
\ 'ivory2': '#eeeee0',
|
||||
\ 'ivory3': '#cdcdc1',
|
||||
\ 'ivory4': '#8b8b83',
|
||||
\ 'honeydew1': '#f0fff0',
|
||||
\ 'honeydew2': '#e0eee0',
|
||||
\ 'honeydew3': '#c1cdc1',
|
||||
\ 'honeydew4': '#838b83',
|
||||
\ 'lavenderblush1': '#fff0f5',
|
||||
\ 'lavenderblush2': '#eee0e5',
|
||||
\ 'lavenderblush3': '#cdc1c5',
|
||||
\ 'lavenderblush4': '#8b8386',
|
||||
\ 'mistyrose1': '#ffe4e1',
|
||||
\ 'mistyrose2': '#eed5d2',
|
||||
\ 'mistyrose3': '#cdb7b5',
|
||||
\ 'mistyrose4': '#8b7d7b',
|
||||
\ 'azure1': '#f0ffff',
|
||||
\ 'azure2': '#e0eeee',
|
||||
\ 'azure3': '#c1cdcd',
|
||||
\ 'azure4': '#838b8b',
|
||||
\ 'slateblue1': '#836fff',
|
||||
\ 'slateblue2': '#7a67ee',
|
||||
\ 'slateblue3': '#6959cd',
|
||||
\ 'slateblue4': '#473c8b',
|
||||
\ 'royalblue1': '#4876ff',
|
||||
\ 'royalblue2': '#436eee',
|
||||
\ 'royalblue3': '#3a5fcd',
|
||||
\ 'royalblue4': '#27408b',
|
||||
\ 'blue1': '#0000ff',
|
||||
\ 'blue2': '#0000ee',
|
||||
\ 'blue3': '#0000cd',
|
||||
\ 'blue4': '#00008b',
|
||||
\ 'dodgerblue1': '#1e90ff',
|
||||
\ 'dodgerblue2': '#1c86ee',
|
||||
\ 'dodgerblue3': '#1874cd',
|
||||
\ 'dodgerblue4': '#104e8b',
|
||||
\ 'steelblue1': '#63b8ff',
|
||||
\ 'steelblue2': '#5cacee',
|
||||
\ 'steelblue3': '#4f94cd',
|
||||
\ 'steelblue4': '#36648b',
|
||||
\ 'deepskyblue1': '#00bfff',
|
||||
\ 'deepskyblue2': '#00b2ee',
|
||||
\ 'deepskyblue3': '#009acd',
|
||||
\ 'deepskyblue4': '#00688b',
|
||||
\ 'skyblue1': '#87ceff',
|
||||
\ 'skyblue2': '#7ec0ee',
|
||||
\ 'skyblue3': '#6ca6cd',
|
||||
\ 'skyblue4': '#4a708b',
|
||||
\ 'lightskyblue1': '#b0e2ff',
|
||||
\ 'lightskyblue2': '#a4d3ee',
|
||||
\ 'lightskyblue3': '#8db6cd',
|
||||
\ 'lightskyblue4': '#607b8b',
|
||||
\ 'slategray1': '#c6e2ff',
|
||||
\ 'slategray2': '#b9d3ee',
|
||||
\ 'slategray3': '#9fb6cd',
|
||||
\ 'slategray4': '#6c7b8b',
|
||||
\ 'lightsteelblue1': '#cae1ff',
|
||||
\ 'lightsteelblue2': '#bcd2ee',
|
||||
\ 'lightsteelblue3': '#a2b5cd',
|
||||
\ 'lightsteelblue4': '#6e7b8b',
|
||||
\ 'lightblue1': '#bfefff',
|
||||
\ 'lightblue2': '#b2dfee',
|
||||
\ 'lightblue3': '#9ac0cd',
|
||||
\ 'lightblue4': '#68838b',
|
||||
\ 'lightcyan1': '#e0ffff',
|
||||
\ 'lightcyan2': '#d1eeee',
|
||||
\ 'lightcyan3': '#b4cdcd',
|
||||
\ 'lightcyan4': '#7a8b8b',
|
||||
\ 'paleturquoise1': '#bbffff',
|
||||
\ 'paleturquoise2': '#aeeeee',
|
||||
\ 'paleturquoise3': '#96cdcd',
|
||||
\ 'paleturquoise4': '#668b8b',
|
||||
\ 'cadetblue1': '#98f5ff',
|
||||
\ 'cadetblue2': '#8ee5ee',
|
||||
\ 'cadetblue3': '#7ac5cd',
|
||||
\ 'cadetblue4': '#53868b',
|
||||
\ 'turquoise1': '#00f5ff',
|
||||
\ 'turquoise2': '#00e5ee',
|
||||
\ 'turquoise3': '#00c5cd',
|
||||
\ 'turquoise4': '#00868b',
|
||||
\ 'cyan1': '#00ffff',
|
||||
\ 'cyan2': '#00eeee',
|
||||
\ 'cyan3': '#00cdcd',
|
||||
\ 'cyan4': '#008b8b',
|
||||
\ 'darkslategray1': '#97ffff',
|
||||
\ 'darkslategray2': '#8deeee',
|
||||
\ 'darkslategray3': '#79cdcd',
|
||||
\ 'darkslategray4': '#528b8b',
|
||||
\ 'aquamarine1': '#7fffd4',
|
||||
\ 'aquamarine2': '#76eec6',
|
||||
\ 'aquamarine3': '#66cdaa',
|
||||
\ 'aquamarine4': '#458b74',
|
||||
\ 'darkseagreen1': '#c1ffc1',
|
||||
\ 'darkseagreen2': '#b4eeb4',
|
||||
\ 'darkseagreen3': '#9bcd9b',
|
||||
\ 'darkseagreen4': '#698b69',
|
||||
\ 'seagreen1': '#54ff9f',
|
||||
\ 'seagreen2': '#4eee94',
|
||||
\ 'seagreen3': '#43cd80',
|
||||
\ 'seagreen4': '#2e8b57',
|
||||
\ 'palegreen1': '#9aff9a',
|
||||
\ 'palegreen2': '#90ee90',
|
||||
\ 'palegreen3': '#7ccd7c',
|
||||
\ 'palegreen4': '#548b54',
|
||||
\ 'springgreen1': '#00ff7f',
|
||||
\ 'springgreen2': '#00ee76',
|
||||
\ 'springgreen3': '#00cd66',
|
||||
\ 'springgreen4': '#008b45',
|
||||
\ 'green1': '#00ff00',
|
||||
\ 'green2': '#00ee00',
|
||||
\ 'green3': '#00cd00',
|
||||
\ 'green4': '#008b00',
|
||||
\ 'chartreuse1': '#7fff00',
|
||||
\ 'chartreuse2': '#76ee00',
|
||||
\ 'chartreuse3': '#66cd00',
|
||||
\ 'chartreuse4': '#458b00',
|
||||
\ 'olivedrab1': '#c0ff3e',
|
||||
\ 'olivedrab2': '#b3ee3a',
|
||||
\ 'olivedrab3': '#9acd32',
|
||||
\ 'olivedrab4': '#698b22',
|
||||
\ 'darkolivegreen1': '#caff70',
|
||||
\ 'darkolivegreen2': '#bcee68',
|
||||
\ 'darkolivegreen3': '#a2cd5a',
|
||||
\ 'darkolivegreen4': '#6e8b3d',
|
||||
\ 'khaki1': '#fff68f',
|
||||
\ 'khaki2': '#eee685',
|
||||
\ 'khaki3': '#cdc673',
|
||||
\ 'khaki4': '#8b864e',
|
||||
\ 'lightgoldenrod1': '#ffec8b',
|
||||
\ 'lightgoldenrod2': '#eedc82',
|
||||
\ 'lightgoldenrod3': '#cdbe70',
|
||||
\ 'lightgoldenrod4': '#8b814c',
|
||||
\ 'lightyellow1': '#ffffe0',
|
||||
\ 'lightyellow2': '#eeeed1',
|
||||
\ 'lightyellow3': '#cdcdb4',
|
||||
\ 'lightyellow4': '#8b8b7a',
|
||||
\ 'yellow1': '#ffff00',
|
||||
\ 'yellow2': '#eeee00',
|
||||
\ 'yellow3': '#cdcd00',
|
||||
\ 'yellow4': '#8b8b00',
|
||||
\ 'gold1': '#ffd700',
|
||||
\ 'gold2': '#eec900',
|
||||
\ 'gold3': '#cdad00',
|
||||
\ 'gold4': '#8b7500',
|
||||
\ 'goldenrod1': '#ffc125',
|
||||
\ 'goldenrod2': '#eeb422',
|
||||
\ 'goldenrod3': '#cd9b1d',
|
||||
\ 'goldenrod4': '#8b6914',
|
||||
\ 'darkgoldenrod1': '#ffb90f',
|
||||
\ 'darkgoldenrod2': '#eead0e',
|
||||
\ 'darkgoldenrod3': '#cd950c',
|
||||
\ 'darkgoldenrod4': '#8b6508',
|
||||
\ 'rosybrown1': '#ffc1c1',
|
||||
\ 'rosybrown2': '#eeb4b4',
|
||||
\ 'rosybrown3': '#cd9b9b',
|
||||
\ 'rosybrown4': '#8b6969',
|
||||
\ 'indianred1': '#ff6a6a',
|
||||
\ 'indianred2': '#ee6363',
|
||||
\ 'indianred3': '#cd5555',
|
||||
\ 'indianred4': '#8b3a3a',
|
||||
\ 'sienna1': '#ff8247',
|
||||
\ 'sienna2': '#ee7942',
|
||||
\ 'sienna3': '#cd6839',
|
||||
\ 'sienna4': '#8b4726',
|
||||
\ 'burlywood1': '#ffd39b',
|
||||
\ 'burlywood2': '#eec591',
|
||||
\ 'burlywood3': '#cdaa7d',
|
||||
\ 'burlywood4': '#8b7355',
|
||||
\ 'wheat1': '#ffe7ba',
|
||||
\ 'wheat2': '#eed8ae',
|
||||
\ 'wheat3': '#cdba96',
|
||||
\ 'wheat4': '#8b7e66',
|
||||
\ 'tan1': '#ffa54f',
|
||||
\ 'tan2': '#ee9a49',
|
||||
\ 'tan3': '#cd853f',
|
||||
\ 'tan4': '#8b5a2b',
|
||||
\ 'chocolate1': '#ff7f24',
|
||||
\ 'chocolate2': '#ee7621',
|
||||
\ 'chocolate3': '#cd661d',
|
||||
\ 'chocolate4': '#8b4513',
|
||||
\ 'firebrick1': '#ff3030',
|
||||
\ 'firebrick2': '#ee2c2c',
|
||||
\ 'firebrick3': '#cd2626',
|
||||
\ 'firebrick4': '#8b1a1a',
|
||||
\ 'brown1': '#ff4040',
|
||||
\ 'brown2': '#ee3b3b',
|
||||
\ 'brown3': '#cd3333',
|
||||
\ 'brown4': '#8b2323',
|
||||
\ 'salmon1': '#ff8c69',
|
||||
\ 'salmon2': '#ee8262',
|
||||
\ 'salmon3': '#cd7054',
|
||||
\ 'salmon4': '#8b4c39',
|
||||
\ 'lightsalmon1': '#ffa07a',
|
||||
\ 'lightsalmon2': '#ee9572',
|
||||
\ 'lightsalmon3': '#cd8162',
|
||||
\ 'lightsalmon4': '#8b5742',
|
||||
\ 'orange1': '#ffa500',
|
||||
\ 'orange2': '#ee9a00',
|
||||
\ 'orange3': '#cd8500',
|
||||
\ 'orange4': '#8b5a00',
|
||||
\ 'darkorange1': '#ff7f00',
|
||||
\ 'darkorange2': '#ee7600',
|
||||
\ 'darkorange3': '#cd6600',
|
||||
\ 'darkorange4': '#8b4500',
|
||||
\ 'coral1': '#ff7256',
|
||||
\ 'coral2': '#ee6a50',
|
||||
\ 'coral3': '#cd5b45',
|
||||
\ 'coral4': '#8b3e2f',
|
||||
\ 'tomato1': '#ff6347',
|
||||
\ 'tomato2': '#ee5c42',
|
||||
\ 'tomato3': '#cd4f39',
|
||||
\ 'tomato4': '#8b3626',
|
||||
\ 'orangered1': '#ff4500',
|
||||
\ 'orangered2': '#ee4000',
|
||||
\ 'orangered3': '#cd3700',
|
||||
\ 'orangered4': '#8b2500',
|
||||
\ 'red1': '#ff0000',
|
||||
\ 'red2': '#ee0000',
|
||||
\ 'red3': '#cd0000',
|
||||
\ 'red4': '#8b0000',
|
||||
\ 'deeppink1': '#ff1493',
|
||||
\ 'deeppink2': '#ee1289',
|
||||
\ 'deeppink3': '#cd1076',
|
||||
\ 'deeppink4': '#8b0a50',
|
||||
\ 'hotpink1': '#ff6eb4',
|
||||
\ 'hotpink2': '#ee6aa7',
|
||||
\ 'hotpink3': '#cd6090',
|
||||
\ 'hotpink4': '#8b3a62',
|
||||
\ 'pink1': '#ffb5c5',
|
||||
\ 'pink2': '#eea9b8',
|
||||
\ 'pink3': '#cd919e',
|
||||
\ 'pink4': '#8b636c',
|
||||
\ 'lightpink1': '#ffaeb9',
|
||||
\ 'lightpink2': '#eea2ad',
|
||||
\ 'lightpink3': '#cd8c95',
|
||||
\ 'lightpink4': '#8b5f65',
|
||||
\ 'palevioletred1': '#ff82ab',
|
||||
\ 'palevioletred2': '#ee799f',
|
||||
\ 'palevioletred3': '#cd6889',
|
||||
\ 'palevioletred4': '#8b475d',
|
||||
\ 'maroon1': '#ff34b3',
|
||||
\ 'maroon2': '#ee30a7',
|
||||
\ 'maroon3': '#cd2990',
|
||||
\ 'maroon4': '#8b1c62',
|
||||
\ 'violetred1': '#ff3e96',
|
||||
\ 'violetred2': '#ee3a8c',
|
||||
\ 'violetred3': '#cd3278',
|
||||
\ 'violetred4': '#8b2252',
|
||||
\ 'magenta1': '#ff00ff',
|
||||
\ 'magenta2': '#ee00ee',
|
||||
\ 'magenta3': '#cd00cd',
|
||||
\ 'magenta4': '#8b008b',
|
||||
\ 'orchid1': '#ff83fa',
|
||||
\ 'orchid2': '#ee7ae9',
|
||||
\ 'orchid3': '#cd69c9',
|
||||
\ 'orchid4': '#8b4789',
|
||||
\ 'plum1': '#ffbbff',
|
||||
\ 'plum2': '#eeaeee',
|
||||
\ 'plum3': '#cd96cd',
|
||||
\ 'plum4': '#8b668b',
|
||||
\ 'mediumorchid1': '#e066ff',
|
||||
\ 'mediumorchid2': '#d15fee',
|
||||
\ 'mediumorchid3': '#b452cd',
|
||||
\ 'mediumorchid4': '#7a378b',
|
||||
\ 'darkorchid1': '#bf3eff',
|
||||
\ 'darkorchid2': '#b23aee',
|
||||
\ 'darkorchid3': '#9a32cd',
|
||||
\ 'darkorchid4': '#68228b',
|
||||
\ 'purple1': '#9b30ff',
|
||||
\ 'purple2': '#912cee',
|
||||
\ 'purple3': '#7d26cd',
|
||||
\ 'purple4': '#551a8b',
|
||||
\ 'mediumpurple1': '#ab82ff',
|
||||
\ 'mediumpurple2': '#9f79ee',
|
||||
\ 'mediumpurple3': '#8968cd',
|
||||
\ 'mediumpurple4': '#5d478b',
|
||||
\ 'thistle1': '#ffe1ff',
|
||||
\ 'thistle2': '#eed2ee',
|
||||
\ 'thistle3': '#cdb5cd',
|
||||
\ 'thistle4': '#8b7b8b',
|
||||
\ 'gray0': '#000000',
|
||||
\ 'grey0': '#000000',
|
||||
\ 'gray1': '#030303',
|
||||
\ 'grey1': '#030303',
|
||||
\ 'gray2': '#050505',
|
||||
\ 'grey2': '#050505',
|
||||
\ 'gray3': '#080808',
|
||||
\ 'grey3': '#080808',
|
||||
\ 'gray4': '#0a0a0a',
|
||||
\ 'grey4': '#0a0a0a',
|
||||
\ 'gray5': '#0d0d0d',
|
||||
\ 'grey5': '#0d0d0d',
|
||||
\ 'gray6': '#0f0f0f',
|
||||
\ 'grey6': '#0f0f0f',
|
||||
\ 'gray7': '#121212',
|
||||
\ 'grey7': '#121212',
|
||||
\ 'gray8': '#141414',
|
||||
\ 'grey8': '#141414',
|
||||
\ 'gray9': '#171717',
|
||||
\ 'grey9': '#171717',
|
||||
\ 'gray10': '#1a1a1a',
|
||||
\ 'grey10': '#1a1a1a',
|
||||
\ 'gray11': '#1c1c1c',
|
||||
\ 'grey11': '#1c1c1c',
|
||||
\ 'gray12': '#1f1f1f',
|
||||
\ 'grey12': '#1f1f1f',
|
||||
\ 'gray13': '#212121',
|
||||
\ 'grey13': '#212121',
|
||||
\ 'gray14': '#242424',
|
||||
\ 'grey14': '#242424',
|
||||
\ 'gray15': '#262626',
|
||||
\ 'grey15': '#262626',
|
||||
\ 'gray16': '#292929',
|
||||
\ 'grey16': '#292929',
|
||||
\ 'gray17': '#2b2b2b',
|
||||
\ 'grey17': '#2b2b2b',
|
||||
\ 'gray18': '#2e2e2e',
|
||||
\ 'grey18': '#2e2e2e',
|
||||
\ 'gray19': '#303030',
|
||||
\ 'grey19': '#303030',
|
||||
\ 'gray20': '#333333',
|
||||
\ 'grey20': '#333333',
|
||||
\ 'gray21': '#363636',
|
||||
\ 'grey21': '#363636',
|
||||
\ 'gray22': '#383838',
|
||||
\ 'grey22': '#383838',
|
||||
\ 'gray23': '#3b3b3b',
|
||||
\ 'grey23': '#3b3b3b',
|
||||
\ 'gray24': '#3d3d3d',
|
||||
\ 'grey24': '#3d3d3d',
|
||||
\ 'gray25': '#404040',
|
||||
\ 'grey25': '#404040',
|
||||
\ 'gray26': '#424242',
|
||||
\ 'grey26': '#424242',
|
||||
\ 'gray27': '#454545',
|
||||
\ 'grey27': '#454545',
|
||||
\ 'gray28': '#474747',
|
||||
\ 'grey28': '#474747',
|
||||
\ 'gray29': '#4a4a4a',
|
||||
\ 'grey29': '#4a4a4a',
|
||||
\ 'gray30': '#4d4d4d',
|
||||
\ 'grey30': '#4d4d4d',
|
||||
\ 'gray31': '#4f4f4f',
|
||||
\ 'grey31': '#4f4f4f',
|
||||
\ 'gray32': '#525252',
|
||||
\ 'grey32': '#525252',
|
||||
\ 'gray33': '#545454',
|
||||
\ 'grey33': '#545454',
|
||||
\ 'gray34': '#575757',
|
||||
\ 'grey34': '#575757',
|
||||
\ 'gray35': '#595959',
|
||||
\ 'grey35': '#595959',
|
||||
\ 'gray36': '#5c5c5c',
|
||||
\ 'grey36': '#5c5c5c',
|
||||
\ 'gray37': '#5e5e5e',
|
||||
\ 'grey37': '#5e5e5e',
|
||||
\ 'gray38': '#616161',
|
||||
\ 'grey38': '#616161',
|
||||
\ 'gray39': '#636363',
|
||||
\ 'grey39': '#636363',
|
||||
\ 'gray40': '#666666',
|
||||
\ 'grey40': '#666666',
|
||||
\ 'gray41': '#696969',
|
||||
\ 'grey41': '#696969',
|
||||
\ 'gray42': '#6b6b6b',
|
||||
\ 'grey42': '#6b6b6b',
|
||||
\ 'gray43': '#6e6e6e',
|
||||
\ 'grey43': '#6e6e6e',
|
||||
\ 'gray44': '#707070',
|
||||
\ 'grey44': '#707070',
|
||||
\ 'gray45': '#737373',
|
||||
\ 'grey45': '#737373',
|
||||
\ 'gray46': '#757575',
|
||||
\ 'grey46': '#757575',
|
||||
\ 'gray47': '#787878',
|
||||
\ 'grey47': '#787878',
|
||||
\ 'gray48': '#7a7a7a',
|
||||
\ 'grey48': '#7a7a7a',
|
||||
\ 'gray49': '#7d7d7d',
|
||||
\ 'grey49': '#7d7d7d',
|
||||
\ 'gray50': '#7f7f7f',
|
||||
\ 'grey50': '#7f7f7f',
|
||||
\ 'gray51': '#828282',
|
||||
\ 'grey51': '#828282',
|
||||
\ 'gray52': '#858585',
|
||||
\ 'grey52': '#858585',
|
||||
\ 'gray53': '#878787',
|
||||
\ 'grey53': '#878787',
|
||||
\ 'gray54': '#8a8a8a',
|
||||
\ 'grey54': '#8a8a8a',
|
||||
\ 'gray55': '#8c8c8c',
|
||||
\ 'grey55': '#8c8c8c',
|
||||
\ 'gray56': '#8f8f8f',
|
||||
\ 'grey56': '#8f8f8f',
|
||||
\ 'gray57': '#919191',
|
||||
\ 'grey57': '#919191',
|
||||
\ 'gray58': '#949494',
|
||||
\ 'grey58': '#949494',
|
||||
\ 'gray59': '#969696',
|
||||
\ 'grey59': '#969696',
|
||||
\ 'gray60': '#999999',
|
||||
\ 'grey60': '#999999',
|
||||
\ 'gray61': '#9c9c9c',
|
||||
\ 'grey61': '#9c9c9c',
|
||||
\ 'gray62': '#9e9e9e',
|
||||
\ 'grey62': '#9e9e9e',
|
||||
\ 'gray63': '#a1a1a1',
|
||||
\ 'grey63': '#a1a1a1',
|
||||
\ 'gray64': '#a3a3a3',
|
||||
\ 'grey64': '#a3a3a3',
|
||||
\ 'gray65': '#a6a6a6',
|
||||
\ 'grey65': '#a6a6a6',
|
||||
\ 'gray66': '#a8a8a8',
|
||||
\ 'grey66': '#a8a8a8',
|
||||
\ 'gray67': '#ababab',
|
||||
\ 'grey67': '#ababab',
|
||||
\ 'gray68': '#adadad',
|
||||
\ 'grey68': '#adadad',
|
||||
\ 'gray69': '#b0b0b0',
|
||||
\ 'grey69': '#b0b0b0',
|
||||
\ 'gray70': '#b3b3b3',
|
||||
\ 'grey70': '#b3b3b3',
|
||||
\ 'gray71': '#b5b5b5',
|
||||
\ 'grey71': '#b5b5b5',
|
||||
\ 'gray72': '#b8b8b8',
|
||||
\ 'grey72': '#b8b8b8',
|
||||
\ 'gray73': '#bababa',
|
||||
\ 'grey73': '#bababa',
|
||||
\ 'gray74': '#bdbdbd',
|
||||
\ 'grey74': '#bdbdbd',
|
||||
\ 'gray75': '#bfbfbf',
|
||||
\ 'grey75': '#bfbfbf',
|
||||
\ 'gray76': '#c2c2c2',
|
||||
\ 'grey76': '#c2c2c2',
|
||||
\ 'gray77': '#c4c4c4',
|
||||
\ 'grey77': '#c4c4c4',
|
||||
\ 'gray78': '#c7c7c7',
|
||||
\ 'grey78': '#c7c7c7',
|
||||
\ 'gray79': '#c9c9c9',
|
||||
\ 'grey79': '#c9c9c9',
|
||||
\ 'gray80': '#cccccc',
|
||||
\ 'grey80': '#cccccc',
|
||||
\ 'gray81': '#cfcfcf',
|
||||
\ 'grey81': '#cfcfcf',
|
||||
\ 'gray82': '#d1d1d1',
|
||||
\ 'grey82': '#d1d1d1',
|
||||
\ 'gray83': '#d4d4d4',
|
||||
\ 'grey83': '#d4d4d4',
|
||||
\ 'gray84': '#d6d6d6',
|
||||
\ 'grey84': '#d6d6d6',
|
||||
\ 'gray85': '#d9d9d9',
|
||||
\ 'grey85': '#d9d9d9',
|
||||
\ 'gray86': '#dbdbdb',
|
||||
\ 'grey86': '#dbdbdb',
|
||||
\ 'gray87': '#dedede',
|
||||
\ 'grey87': '#dedede',
|
||||
\ 'gray88': '#e0e0e0',
|
||||
\ 'grey88': '#e0e0e0',
|
||||
\ 'gray89': '#e3e3e3',
|
||||
\ 'grey89': '#e3e3e3',
|
||||
\ 'gray90': '#e5e5e5',
|
||||
\ 'grey90': '#e5e5e5',
|
||||
\ 'gray91': '#e8e8e8',
|
||||
\ 'grey91': '#e8e8e8',
|
||||
\ 'gray92': '#ebebeb',
|
||||
\ 'grey92': '#ebebeb',
|
||||
\ 'gray93': '#ededed',
|
||||
\ 'grey93': '#ededed',
|
||||
\ 'gray94': '#f0f0f0',
|
||||
\ 'grey94': '#f0f0f0',
|
||||
\ 'gray95': '#f2f2f2',
|
||||
\ 'grey95': '#f2f2f2',
|
||||
\ 'gray96': '#f5f5f5',
|
||||
\ 'grey96': '#f5f5f5',
|
||||
\ 'gray97': '#f7f7f7',
|
||||
\ 'grey97': '#f7f7f7',
|
||||
\ 'gray98': '#fafafa',
|
||||
\ 'grey98': '#fafafa',
|
||||
\ 'gray99': '#fcfcfc',
|
||||
\ 'grey99': '#fcfcfc',
|
||||
\ 'gray100': '#ffffff',
|
||||
\ 'grey100': '#ffffff',
|
||||
\ 'dark grey': '#a9a9a9',
|
||||
\ 'darkgrey': '#a9a9a9',
|
||||
\ 'dark gray': '#a9a9a9',
|
||||
\ 'darkgray': '#a9a9a9',
|
||||
\ 'dark blue': '#00008b',
|
||||
\ 'darkblue': '#00008b',
|
||||
\ 'dark cyan': '#008b8b',
|
||||
\ 'darkcyan': '#008b8b',
|
||||
\ 'dark magenta': '#8b008b',
|
||||
\ 'darkmagenta': '#8b008b',
|
||||
\ 'dark red': '#8b0000',
|
||||
\ 'darkred': '#8b0000',
|
||||
\ 'light green': '#90ee90',
|
||||
\ 'lightgreen': '#90ee90',
|
||||
\ 'crimson': '#dc143c',
|
||||
\ 'indigo': '#4b0082',
|
||||
\ 'olive': '#808000',
|
||||
\ 'rebecca purple': '#663399',
|
||||
\ 'rebeccapurple': '#663399',
|
||||
\ 'silver': '#c0c0c0',
|
||||
\ 'teal': '#008080'
|
||||
\ }, 'keep')
|
||||
|
||||
let &cpo= s:keepcpo
|
||||
unlet s:keepcpo
|
||||
|
||||
"vim: sw=4
|
||||
@@ -226,7 +226,13 @@ fu! Result(err)
|
||||
endif
|
||||
endfu
|
||||
|
||||
call Test_check_colors()
|
||||
|
||||
let &cpo = s:save_cpo
|
||||
unlet s:save_cpo
|
||||
try
|
||||
call Test_check_colors()
|
||||
catch
|
||||
echohl ErrorMsg
|
||||
echomsg v:exception
|
||||
echohl NONE
|
||||
finally
|
||||
let &cpo = s:save_cpo
|
||||
unlet s:save_cpo
|
||||
endtry
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" The default vimrc file.
|
||||
"
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last change: 2020 Sep 30
|
||||
" Last change: 2021 Nov 17
|
||||
"
|
||||
" This is loaded if no vimrc file was found.
|
||||
" Except when Vim is run with "-u NONE" or "-C".
|
||||
@@ -96,7 +96,7 @@ if 1
|
||||
filetype plugin indent on
|
||||
|
||||
" Put these in an autocmd group, so that you can revert them with:
|
||||
" ":augroup vimStartup | au! | augroup END"
|
||||
" ":augroup vimStartup | exe 'au!' | augroup END"
|
||||
augroup vimStartup
|
||||
au!
|
||||
|
||||
@@ -111,6 +111,18 @@ if 1
|
||||
|
||||
augroup END
|
||||
|
||||
" Quite a few people accidentally type "q:" instead of ":q" and get confused
|
||||
" by the command line window. Give a hint about how to get out.
|
||||
" If you don't like this you can put this in your vimrc:
|
||||
" ":augroup vimHints | exe 'au!' | augroup END"
|
||||
augroup vimHints
|
||||
au!
|
||||
autocmd CmdwinEnter *
|
||||
\ echohl Todo |
|
||||
\ echo 'You discovered the command-line window! You can close it with ":q".' |
|
||||
\ echohl None
|
||||
augroup END
|
||||
|
||||
endif
|
||||
|
||||
" Switch syntax highlighting on when the terminal has colors or when using the
|
||||
|
||||
@@ -16,6 +16,7 @@ include ../../src/auto/config.mk
|
||||
DOCS = \
|
||||
arabic.txt \
|
||||
autocmd.txt \
|
||||
builtin.txt \
|
||||
change.txt \
|
||||
channel.txt \
|
||||
cmdline.txt \
|
||||
@@ -161,6 +162,7 @@ DOCS = \
|
||||
HTMLS = \
|
||||
arabic.html \
|
||||
autocmd.html \
|
||||
builtin.html \
|
||||
change.html \
|
||||
channel.html \
|
||||
cmdline.html \
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*autocmd.txt* For Vim version 8.2. Last change: 2021 Oct 04
|
||||
*autocmd.txt* For Vim version 8.2. Last change: 2021 Nov 20
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -83,7 +83,7 @@ triggered.
|
||||
}
|
||||
|
||||
Note: The ":autocmd" command can only be followed by another command when the
|
||||
'|' appears before {cmd}. This works: >
|
||||
'|' appears where the pattern is expected. This works: >
|
||||
:augroup mine | au! BufRead | augroup END
|
||||
But this sees "augroup" as part of the defined command: >
|
||||
:augroup mine | au! BufRead * | augroup END
|
||||
@@ -348,6 +348,7 @@ Name triggered by ~
|
||||
|
||||
|WinNew| after creating a new window
|
||||
|TabNew| after creating a new tab page
|
||||
|WinClosed| after closing a window
|
||||
|TabClosed| after closing a tab page
|
||||
|WinEnter| after entering another window
|
||||
|WinLeave| before leaving a window
|
||||
@@ -930,18 +931,23 @@ MenuPopup Just before showing the popup menu (under the
|
||||
*ModeChanged*
|
||||
ModeChanged After changing the mode. The pattern is
|
||||
matched against `'old_mode:new_mode'`, for
|
||||
example match against `i:*` to simulate
|
||||
|InsertLeave|.
|
||||
example match against `*:c*` to simulate
|
||||
|CmdlineEnter|.
|
||||
The following values of |v:event| are set:
|
||||
old_mode The mode before it changed.
|
||||
new_mode The new mode as also returned
|
||||
by |mode()|.
|
||||
by |mode()| called with a
|
||||
non-zero argument.
|
||||
When ModeChanged is triggered, old_mode will
|
||||
have the value of new_mode when the event was
|
||||
last triggered.
|
||||
This will be triggered on every minor mode
|
||||
change.
|
||||
Usage example to use relative line numbers
|
||||
when entering Visual mode: >
|
||||
:autocmd ModeChanged *:v set relativenumber
|
||||
:au ModeChanged [vV\x16]*:* let &l:rnu = mode() =~# '^[vV\x16]'
|
||||
:au ModeChanged *:[vV\x16]* let &l:rnu = mode() =~# '^[vV\x16]'
|
||||
:au WinEnter,WinLeave * let &l:rnu = mode() =~# '^[vV\x16]'
|
||||
< *OptionSet*
|
||||
OptionSet After setting an option. The pattern is
|
||||
matched against the long option name.
|
||||
@@ -1273,8 +1279,14 @@ VimResume When the Vim instance is resumed after being
|
||||
:autocmd VimResume * checktime
|
||||
< *VimSuspend*
|
||||
VimSuspend When the Vim instance is suspended. Only when
|
||||
CTRL-Z was typed inside Vim, not when the
|
||||
SIGSTOP or SIGTSTP signal was sent to Vim.
|
||||
CTRL-Z was typed inside Vim, or when the SIGTSTP
|
||||
signal was sent to Vim, but not for SIGSTOP.
|
||||
*WinClosed*
|
||||
WinClosed After closing a window. The pattern is
|
||||
matched against the |window-ID|. Both
|
||||
<amatch> and <afile> are set to the
|
||||
|window-ID|. Non-recursive (event cannot
|
||||
trigger itself).
|
||||
*WinEnter*
|
||||
WinEnter After entering another window. Not done for
|
||||
the first window, when Vim has just started.
|
||||
|
||||
10132
runtime/doc/builtin.txt
Normal file
10132
runtime/doc/builtin.txt
Normal file
File diff suppressed because it is too large
Load Diff
@@ -1,4 +1,4 @@
|
||||
*change.txt* For Vim version 8.2. Last change: 2021 Jun 23
|
||||
*change.txt* For Vim version 8.2. Last change: 2021 Dec 29
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -259,6 +259,9 @@ Or use "caw" (see |aw|).
|
||||
line.
|
||||
Adding [!] toggles 'autoindent' for the time this
|
||||
command is executed.
|
||||
This command is not supported in |Vim9| script,
|
||||
because it is too easily confused with a variable
|
||||
name.
|
||||
|
||||
==============================================================================
|
||||
3. Simple changes *simple-change*
|
||||
@@ -1374,6 +1377,9 @@ The next three commands always work on whole lines.
|
||||
|
||||
*:t*
|
||||
:t Synonym for copy.
|
||||
This command is not supported in |Vim9| script,
|
||||
because it is too easily confused with a variable
|
||||
name.
|
||||
|
||||
:[range]m[ove] {address} *:m* *:mo* *:move* *E134*
|
||||
Move the lines given by [range] to below the line
|
||||
@@ -1671,7 +1677,8 @@ r Automatically insert the current comment leader after hitting
|
||||
<Enter> in Insert mode.
|
||||
*fo-o*
|
||||
o Automatically insert the current comment leader after hitting 'o' or
|
||||
'O' in Normal mode.
|
||||
'O' in Normal mode. In case comment is unwanted in a specific place
|
||||
use CTRL-U to quickly delete it. |i_CTRL-U|
|
||||
*fo-q*
|
||||
q Allow formatting of comments with "gq".
|
||||
Note that formatting will not change blank lines or lines containing
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*channel.txt* For Vim version 8.2. Last change: 2020 Oct 17
|
||||
*channel.txt* For Vim version 8.2. Last change: 2021 Nov 28
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -101,7 +101,7 @@ Instead of giving a callback with every send call, it can also be specified
|
||||
when opening the channel: >
|
||||
call ch_close(channel)
|
||||
let channel = ch_open('localhost:8765', {'callback': "MyHandler"})
|
||||
call ch_sendexpr(channel, 'hello!')
|
||||
call ch_sendexpr(channel, 'hello channel!')
|
||||
|
||||
When trying out channels it's useful to see what is going on. You can tell
|
||||
Vim to write lines in log file: >
|
||||
@@ -132,8 +132,9 @@ When using an IPv6 address, enclose it within square brackets. E.g.,
|
||||
"raw" - Use raw messages
|
||||
*channel-callback* *E921*
|
||||
"callback" A function that is called when a message is received that is
|
||||
not handled otherwise. It gets two arguments: the channel
|
||||
and the received message. Example: >
|
||||
not handled otherwise (e.g. a JSON message with ID zero). It
|
||||
gets two arguments: the channel and the received message.
|
||||
Example: >
|
||||
func Handle(channel, msg)
|
||||
echo 'Received: ' . a:msg
|
||||
endfunc
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*cmdline.txt* For Vim version 8.2. Last change: 2021 Aug 06
|
||||
*cmdline.txt* For Vim version 8.2. Last change: 2021 Dec 26
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -705,6 +705,15 @@ Some Ex commands accept a line range in front of them. This is noted as
|
||||
|
||||
The basics are explained in section |10.3| of the user manual.
|
||||
|
||||
In |Vim9| script a range needs to be prefixed with a colon to avoid ambiguity
|
||||
with continuation lines. For example, "+" can be used for a range but is also
|
||||
a continuation of an expression: >
|
||||
var result = start
|
||||
+ print
|
||||
If the "+" is a range then it must be prefixed with a colon: >
|
||||
var result = start
|
||||
:+ print
|
||||
<
|
||||
*:,* *:;*
|
||||
When separated with ';' the cursor position will be set to that line
|
||||
before interpreting the next line specifier. This doesn't happen for ','.
|
||||
@@ -919,15 +928,19 @@ Note: these are typed literally, they are not special keys!
|
||||
*:<amatch>* *<amatch>*
|
||||
<amatch> When executing autocommands, is replaced with the match for
|
||||
which this autocommand was executed. *E497*
|
||||
It differs from <afile> only when the file name isn't used
|
||||
to match with (for FileType, Syntax and SpellFileMissing
|
||||
It differs from <afile> when the file name isn't used to
|
||||
match with (for FileType, Syntax and SpellFileMissing
|
||||
events).
|
||||
When the match is with a file name, it is expanded to the
|
||||
full path.
|
||||
*:<sfile>* *<sfile>*
|
||||
<sfile> When executing a ":source" command, is replaced with the
|
||||
file name of the sourced file. *E498*
|
||||
When executing a function, is replaced with the call stack,
|
||||
as with <stack> (this is for backwards compatibility, using
|
||||
<stack> is preferred).
|
||||
When executing a legacy function, is replaced with the call
|
||||
stack, as with <stack> (this is for backwards
|
||||
compatibility, using <stack> is preferred).
|
||||
In Vim9 script using <sfile> in a function gives error
|
||||
*E1245* .
|
||||
Note that filename-modifiers are useless when <sfile> is
|
||||
not used inside a script.
|
||||
*:<stack>* *<stack>*
|
||||
|
||||
@@ -398,6 +398,11 @@ mode, so that a CTRL-Z doesn't end the text on DOS.
|
||||
The `redraw!` command may not be needed, depending on whether executing a
|
||||
shell command shows something on the display or not.
|
||||
|
||||
If the 'diffexpr' expression starts with s: or |<SID>|, then it is replaced
|
||||
with the script ID (|local-function|). Example: >
|
||||
set diffexpr=s:MyDiffExpr()
|
||||
set diffexpr=<SID>SomeDiffExpr()
|
||||
<
|
||||
*E810* *E97*
|
||||
Vim will do a test if the diff output looks alright. If it doesn't, you will
|
||||
get an error message. Possible causes:
|
||||
@@ -449,4 +454,9 @@ evaluating 'patchexpr'. This hopefully avoids that files in the current
|
||||
directory are accidentally patched. Vim will also delete files starting with
|
||||
v:fname_in and ending in ".rej" and ".orig".
|
||||
|
||||
If the 'patchexpr' expression starts with s: or |<SID>|, then it is replaced
|
||||
with the script ID (|local-function|). Example: >
|
||||
set patchexpr=s:MyPatchExpr()
|
||||
set patchexpr=<SID>SomePatchExpr()
|
||||
<
|
||||
vim:tw=78:ts=8:noet:ft=help:norl:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*editing.txt* For Vim version 8.2. Last change: 2021 Oct 16
|
||||
*editing.txt* For Vim version 8.2. Last change: 2021 Dec 27
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -650,12 +650,19 @@ list of the current window.
|
||||
And after the last one:
|
||||
:+2argadd y a b c x y
|
||||
There is no check for duplicates, it is possible to
|
||||
add a file to the argument list twice.
|
||||
The currently edited file is not changed.
|
||||
add a file to the argument list twice. You can use
|
||||
|:argdedupe| to fix it afterwards: >
|
||||
:argadd *.txt | argdedupe
|
||||
< The currently edited file is not changed.
|
||||
Note: you can also use this method: >
|
||||
:args ## x
|
||||
< This will add the "x" item and sort the new list.
|
||||
|
||||
:argded[upe] *:argded* *:argdedupe*
|
||||
Remove duplicate filenames from the argument list.
|
||||
If your current file is a duplicate, your current file
|
||||
will change to the original file index.
|
||||
|
||||
:argd[elete] {pattern} .. *:argd* *:argdelete* *E480* *E610*
|
||||
Delete files from the argument list that match the
|
||||
{pattern}s. {pattern} is used like a file pattern,
|
||||
@@ -1140,6 +1147,9 @@ The names can be in upper- or lowercase.
|
||||
made.
|
||||
When 'hidden' is set and there are more windows, the
|
||||
current buffer becomes hidden, after writing the file.
|
||||
This command is not supported in |Vim9| script,
|
||||
because it is too easily confused with a variable
|
||||
name.
|
||||
|
||||
*:exi* *:exit*
|
||||
:[range]exi[t][!] [++opt] [file]
|
||||
@@ -1298,11 +1308,12 @@ Changing directory fails when the current buffer is modified, the '.' flag is
|
||||
present in 'cpoptions' and "!" is not used in the command.
|
||||
|
||||
*:cd* *E747* *E472*
|
||||
:cd[!] On non-Unix systems: Print the current directory
|
||||
name. On Unix systems: Change the current directory
|
||||
to the home directory. Use |:pwd| to print the
|
||||
current directory on all systems.
|
||||
On Unix systems: clear any window-local directory.
|
||||
:cd[!] On non-Unix systems when 'cdhome' is off: Print the
|
||||
current directory name.
|
||||
Otherwise: Change the current directory to the home
|
||||
directory. Clear any window-local directory.
|
||||
Use |:pwd| to print the current directory on all
|
||||
systems.
|
||||
|
||||
:cd[!] {path} Change the current directory to {path}.
|
||||
If {path} is relative, it is searched for in the
|
||||
|
||||
10311
runtime/doc/eval.txt
10311
runtime/doc/eval.txt
File diff suppressed because it is too large
Load Diff
@@ -1,4 +1,4 @@
|
||||
*filetype.txt* For Vim version 8.2. Last change: 2021 Sep 22
|
||||
*filetype.txt* For Vim version 8.2. Last change: 2021 Dec 30
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -139,18 +139,19 @@ can be used to overrule the filetype used for certain extensions:
|
||||
|
||||
file name variable ~
|
||||
*.asa g:filetype_asa |ft-aspvbs-syntax| |ft-aspperl-syntax|
|
||||
*.asp g:filetype_asp |ft-aspvbs-syntax| |ft-aspperl-syntax|
|
||||
*.asm g:asmsyntax |ft-asm-syntax|
|
||||
*.prg g:filetype_prg
|
||||
*.pl g:filetype_pl
|
||||
*.inc g:filetype_inc
|
||||
*.w g:filetype_w |ft-cweb-syntax|
|
||||
*.asp g:filetype_asp |ft-aspvbs-syntax| |ft-aspperl-syntax|
|
||||
*.fs g:filetype_fs |ft-forth-syntax|
|
||||
*.i g:filetype_i |ft-progress-syntax|
|
||||
*.inc g:filetype_inc
|
||||
*.m g:filetype_m |ft-mathematica-syntax|
|
||||
*.p g:filetype_p |ft-pascal-syntax|
|
||||
*.pl g:filetype_pl
|
||||
*.pp g:filetype_pp |ft-pascal-syntax|
|
||||
*.prg g:filetype_prg
|
||||
*.sh g:bash_is_sh |ft-sh-syntax|
|
||||
*.tex g:tex_flavor |ft-tex-plugin|
|
||||
*.w g:filetype_w |ft-cweb-syntax|
|
||||
|
||||
*filetype-ignore*
|
||||
To avoid that certain files are being inspected, the g:ft_ignore_pat variable
|
||||
@@ -357,12 +358,12 @@ define yourself. There are a few ways to avoid this:
|
||||
You need to define your own mapping before the plugin is loaded (before
|
||||
editing a file of that type). The plugin will then skip installing the
|
||||
default mapping.
|
||||
*no_mail_maps*
|
||||
*no_mail_maps* *g:no_mail_maps*
|
||||
3. Disable defining mappings for a specific filetype by setting a variable,
|
||||
which contains the name of the filetype. For the "mail" filetype this
|
||||
would be: >
|
||||
:let no_mail_maps = 1
|
||||
< *no_plugin_maps*
|
||||
< *no_plugin_maps* *g:no_plugin_maps*
|
||||
4. Disable defining mappings for all filetypes by setting a variable: >
|
||||
:let no_plugin_maps = 1
|
||||
<
|
||||
|
||||
@@ -121,6 +121,11 @@ method can be very slow!
|
||||
Try to avoid the "=", "a" and "s" return values, since Vim often has to search
|
||||
backwards for a line for which the fold level is defined. This can be slow.
|
||||
|
||||
If the 'foldexpr' expression starts with s: or |<SID>|, then it is replaced
|
||||
with the script ID (|local-function|). Examples: >
|
||||
set foldexpr=s:MyFoldExpr()
|
||||
set foldexpr=<SID>SomeFoldExpr()
|
||||
<
|
||||
An example of using "a1" and "s1": For a multi-line C comment, a line
|
||||
containing "/*" would return "a1" to start a fold, and a line containing "*/"
|
||||
would return "s1" to end the fold after that line: >
|
||||
@@ -524,6 +529,11 @@ The resulting line is truncated to fit in the window, it never wraps.
|
||||
When there is room after the text, it is filled with the character specified
|
||||
by 'fillchars'.
|
||||
|
||||
If the 'foldtext' expression starts with s: or |<SID>|, then it is replaced
|
||||
with the script ID (|local-function|). Examples: >
|
||||
set foldtext=s:MyFoldText()
|
||||
set foldtext=<SID>SomeFoldText()
|
||||
<
|
||||
Note that backslashes need to be used for characters that the ":set" command
|
||||
handles differently: Space, backslash and double-quote. |option-backslash|
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*gui_w32.txt* For Vim version 8.2. Last change: 2021 Apr 05
|
||||
*gui_w32.txt* For Vim version 8.2. Last change: 2021 Oct 24
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -323,20 +323,10 @@ These extra colors are also available:
|
||||
Gray, Grey, LightYellow, SeaGreen, Orange, Purple, SlateBlue, Violet,
|
||||
|
||||
*rgb.txt*
|
||||
Additionally, colors defined by a "rgb.txt" file can be used. This file is
|
||||
well known from X11. A few lines from it: >
|
||||
|
||||
255 218 185 peach puff
|
||||
205 133 63 peru
|
||||
255 181 197 pink
|
||||
|
||||
This shows the layout of the file: First the R, G and B value as a decimal
|
||||
number, followed by the name of the color. The four fields are separated by
|
||||
spaces.
|
||||
|
||||
You can get an rgb.txt file from any X11 distribution. It is located in a
|
||||
directory like "/usr/X11R6/lib/X11/". For Vim it must be located in the
|
||||
$VIMRUNTIME directory. Thus the file can be found with "$VIMRUNTIME/rgb.txt".
|
||||
Additionally, colors defined by a default color list can be used. For more
|
||||
info see |:colorscheme|. These colors used to be defined in
|
||||
$VIMRUNTIME/rgb.txt, now they are in |v:colornames| which is initialized from
|
||||
$VIMRUNTIME/colors/lists/default.vim.
|
||||
|
||||
==============================================================================
|
||||
*gui-w32-dialogs* *dialog*
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*help.txt* For Vim version 8.2. Last change: 2020 Aug 15
|
||||
*help.txt* For Vim version 8.2. Last change: 2021 Dec 27
|
||||
|
||||
VIM - main help file
|
||||
k
|
||||
@@ -136,6 +136,7 @@ Advanced editing ~
|
||||
|diff.txt| working with two to eight versions of the same file
|
||||
|autocmd.txt| automatically executing commands on an event
|
||||
|eval.txt| expression evaluation, conditional commands
|
||||
|builtin.txt| builtin functions
|
||||
|channel.txt| Jobs, Channels, inter-process communication
|
||||
|fold.txt| hide (fold) ranges of lines
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*helphelp.txt* For Vim version 8.2. Last change: 2020 Dec 29
|
||||
*helphelp.txt* For Vim version 8.2. Last change: 2021 Dec 13
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -163,7 +163,7 @@ If you would like to open the help in the current window, see this tip:
|
||||
|
||||
The initial height of the help window can be set with the 'helpheight' option
|
||||
(default 20).
|
||||
|
||||
*help-buffer-options*
|
||||
When the help buffer is created, several local options are set to make sure
|
||||
the help text is displayed as it was intended:
|
||||
'iskeyword' nearly all ASCII chars except ' ', '*', '"' and '|'
|
||||
@@ -323,21 +323,25 @@ Hints for translators:
|
||||
3. Writing help files *help-writing*
|
||||
|
||||
For ease of use, a Vim help file for a plugin should follow the format of the
|
||||
standard Vim help files. If you are writing a new help file it's best to copy
|
||||
one of the existing files and use it as a template.
|
||||
standard Vim help files, except for the first line. If you are writing a new
|
||||
help file it's best to copy one of the existing files and use it as a
|
||||
template.
|
||||
|
||||
The first line in a help file should have the following format:
|
||||
|
||||
*helpfile_name.txt* For Vim version 7.3 Last change: 2010 June 4
|
||||
*plugin_name.txt* {short description of the plugin}
|
||||
|
||||
The first field is a link to the help file name. The second field describes
|
||||
the applicable Vim version. The last field specifies the last modification
|
||||
date of the file. Each field is separated by a tab.
|
||||
The first field is a help tag where ":help plugin_name" will jump to. The
|
||||
remainder of the line, after a Tab, describes the plugin purpose in a short
|
||||
way. This will show up in the "LOCAL ADDITIONS" section of the main help
|
||||
file. Check there that it shows up properly: |local-additions|.
|
||||
|
||||
If you want to add a version number or last modification date, put it in the
|
||||
second line, right aligned.
|
||||
|
||||
At the bottom of the help file, place a Vim modeline to set the 'textwidth'
|
||||
and 'tabstop' options and the 'filetype' to "help". Never set a global option
|
||||
in such a modeline, that can have consequences undesired by whoever reads that
|
||||
help.
|
||||
in such a modeline, that can have undesired consequences.
|
||||
|
||||
|
||||
TAGS
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*if_pyth.txt* For Vim version 8.2. Last change: 2019 Dec 07
|
||||
*if_pyth.txt* For Vim version 8.2. Last change: 2021 Nov 12
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Paul Moore
|
||||
@@ -63,6 +63,11 @@ To see what version of Python you have: >
|
||||
|
||||
There is no need to import sys, it's done by default.
|
||||
|
||||
*python-environment*
|
||||
Environment variables set in Vim are not always available in Python. This
|
||||
depends on how Vim and Python were build. Also see
|
||||
https://docs.python.org/3/library/os.html#os.environ
|
||||
|
||||
Note: Python is very sensitive to the indenting. Make sure the "class" line
|
||||
and "EOF" do not have any indent.
|
||||
|
||||
|
||||
@@ -608,26 +608,25 @@ CLOJURE *ft-clojure-indent* *clojure-indent*
|
||||
Clojure indentation differs somewhat from traditional Lisps, due in part to
|
||||
the use of square and curly brackets, and otherwise by community convention.
|
||||
These conventions are not universally followed, so the Clojure indent script
|
||||
offers a few configurable options, listed below.
|
||||
offers a few configuration options.
|
||||
|
||||
(If the current Vim does not include |searchpairpos()|, the indent script falls
|
||||
back to normal 'lisp' indenting, and the following options are ignored.)
|
||||
|
||||
If the current vim does not include searchpairpos(), the indent script falls
|
||||
back to normal 'lisp' indenting, and the following options are ignored.
|
||||
|
||||
*g:clojure_maxlines*
|
||||
|
||||
Set maximum scan distance of searchpairpos(). Larger values trade performance
|
||||
for correctness when dealing with very long forms. A value of 0 will scan
|
||||
without limits.
|
||||
>
|
||||
" Default
|
||||
let g:clojure_maxlines = 100
|
||||
<
|
||||
Sets maximum scan distance of `searchpairpos()`. Larger values trade
|
||||
performance for correctness when dealing with very long forms. A value of
|
||||
0 will scan without limits. The default is 300.
|
||||
|
||||
|
||||
*g:clojure_fuzzy_indent*
|
||||
*g:clojure_fuzzy_indent_patterns*
|
||||
*g:clojure_fuzzy_indent_blacklist*
|
||||
|
||||
The 'lispwords' option is a list of comma-separated words that mark special
|
||||
forms whose subforms must be indented with two spaces.
|
||||
forms whose subforms should be indented with two spaces.
|
||||
|
||||
For example:
|
||||
>
|
||||
@@ -645,15 +644,11 @@ the fuzzy indent feature:
|
||||
let g:clojure_fuzzy_indent_patterns = ['^with', '^def', '^let']
|
||||
let g:clojure_fuzzy_indent_blacklist =
|
||||
\ ['-fn$', '\v^with-%(meta|out-str|loading-context)$']
|
||||
|
||||
" Legacy comma-delimited string version; the list format above is
|
||||
" recommended. Note that patterns are implicitly anchored with ^ and $
|
||||
let g:clojure_fuzzy_indent_patterns = 'with.*,def.*,let.*'
|
||||
<
|
||||
|g:clojure_fuzzy_indent_patterns| and |g:clojure_fuzzy_indent_blacklist| are
|
||||
|Lists| of patterns that will be matched against the unquoted, unqualified
|
||||
symbol at the head of a list. This means that a pattern like "^foo" will match
|
||||
all these candidates: "foobar", "my.ns/foobar", and "#'foobar".
|
||||
lists of patterns that will be matched against the unqualified symbol at the
|
||||
head of a list. This means that a pattern like `"^foo"` will match all these
|
||||
candidates: `foobar`, `my.ns/foobar`, and `#'foobar`.
|
||||
|
||||
Each candidate word is tested for special treatment in this order:
|
||||
|
||||
@@ -664,20 +659,22 @@ Each candidate word is tested for special treatment in this order:
|
||||
|g:clojure_fuzzy_indent_patterns|
|
||||
4. Return false and indent normally otherwise
|
||||
|
||||
|
||||
*g:clojure_special_indent_words*
|
||||
|
||||
Some forms in Clojure are indented so that every subform is indented only two
|
||||
spaces, regardless of 'lispwords'. If you have a custom construct that should
|
||||
be indented in this idiosyncratic fashion, you can add your symbols to the
|
||||
default list below.
|
||||
Some forms in Clojure are indented such that every subform is indented by only
|
||||
two spaces, regardless of 'lispwords'. If you have a custom construct that
|
||||
should be indented in this idiosyncratic fashion, you can add your symbols to
|
||||
the default list below.
|
||||
>
|
||||
" Default
|
||||
let g:clojure_special_indent_words =
|
||||
\ 'deftype,defrecord,reify,proxy,extend-type,extend-protocol,letfn'
|
||||
<
|
||||
|
||||
*g:clojure_align_multiline_strings*
|
||||
|
||||
Align subsequent lines in multiline strings to the column after the opening
|
||||
Align subsequent lines in multi-line strings to the column after the opening
|
||||
quote, instead of the same column.
|
||||
|
||||
For example:
|
||||
@@ -694,11 +691,7 @@ For example:
|
||||
enim ad minim veniam, quis nostrud exercitation ullamco laboris
|
||||
nisi ut aliquip ex ea commodo consequat.")
|
||||
<
|
||||
This option is off by default.
|
||||
>
|
||||
" Default
|
||||
let g:clojure_align_multiline_strings = 0
|
||||
<
|
||||
|
||||
*g:clojure_align_subforms*
|
||||
|
||||
By default, parenthesized compound forms that look like function calls and
|
||||
@@ -709,18 +702,14 @@ two spaces relative to the opening paren:
|
||||
bar
|
||||
baz)
|
||||
<
|
||||
Setting this option changes this behavior so that all subforms are aligned to
|
||||
the same column, emulating the default behavior of clojure-mode.el:
|
||||
Setting this option to `1` changes this behaviour so that all subforms are
|
||||
aligned to the same column, emulating the default behaviour of
|
||||
clojure-mode.el:
|
||||
>
|
||||
(foo
|
||||
bar
|
||||
baz)
|
||||
<
|
||||
This option is off by default.
|
||||
>
|
||||
" Default
|
||||
let g:clojure_align_subforms = 0
|
||||
<
|
||||
|
||||
FORTRAN *ft-fortran-indent*
|
||||
|
||||
|
||||
@@ -1166,6 +1166,7 @@ tag command action ~
|
||||
be remapped
|
||||
|:args| :ar[gs] print the argument list
|
||||
|:argadd| :arga[dd] add items to the argument list
|
||||
:argdedupe :argdedupe remove duplicates from the argument list
|
||||
|:argdelete| :argd[elete] delete items from the argument list
|
||||
|:argedit| :arge[dit] add item to the argument list and edit it
|
||||
|:argdo| :argdo do a command on all items in the argument list
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*insert.txt* For Vim version 8.2. Last change: 2021 Aug 31
|
||||
*insert.txt* For Vim version 8.2. Last change: 2021 Dec 29
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -84,6 +84,8 @@ CTRL-U Delete all entered characters before the cursor in the current
|
||||
line. If there are no newly entered characters and
|
||||
'backspace' is not empty, delete all characters before the
|
||||
cursor in the current line.
|
||||
If C-indenting is enabled the indent will be adjusted if the
|
||||
line becomes blank.
|
||||
See |i_backspacing| about joining lines.
|
||||
*i_CTRL-I* *i_<Tab>* *i_Tab*
|
||||
<Tab> or CTRL-I Insert a tab. If the 'expandtab' option is on, the
|
||||
@@ -871,31 +873,27 @@ invoked and what it should return.
|
||||
Here is an example that uses the "aiksaurus" command (provided by Magnus
|
||||
Groß): >
|
||||
|
||||
func Thesaur(findstart, base)
|
||||
if a:findstart
|
||||
let line = getline('.')
|
||||
let start = col('.') - 1
|
||||
while start > 0 && line[start - 1] =~ '\a'
|
||||
let start -= 1
|
||||
endwhile
|
||||
return start
|
||||
else
|
||||
let res = []
|
||||
let h = ''
|
||||
for l in split(system('aiksaurus '.shellescape(a:base)), '\n')
|
||||
if l[:3] == '=== '
|
||||
let h = substitute(l[4:], ' =*$', '', '')
|
||||
elseif l[0] =~ '\a'
|
||||
call extend(res, map(split(l, ', '), {_, val -> {'word': val, 'menu': '('.h.')'}}))
|
||||
endif
|
||||
endfor
|
||||
return res
|
||||
endif
|
||||
endfunc
|
||||
|
||||
if has('patch-8.2.3520')
|
||||
set thesaurusfunc=Thesaur
|
||||
func Thesaur(findstart, base)
|
||||
if a:findstart
|
||||
return searchpos('\<', 'bnW', line('.'))[1] - 1
|
||||
endif
|
||||
let res = []
|
||||
let h = ''
|
||||
for l in systemlist('aiksaurus '.shellescape(a:base))
|
||||
if l[:3] == '=== '
|
||||
let h = '('.substitute(l[4:], ' =*$', ')', '')
|
||||
elseif l ==# 'Alphabetically similar known words are: '
|
||||
let h = "\U0001f52e"
|
||||
elseif l[0] =~ '\a' || (h ==# "\U0001f52e" && l[0] ==# "\t")
|
||||
call extend(res, map(split(substitute(l, '^\t', '', ''), ', '), {_, val -> {'word': val, 'menu': h}}))
|
||||
endif
|
||||
endfor
|
||||
return res
|
||||
endfunc
|
||||
|
||||
if exists('+thesaurusfunc')
|
||||
set thesaurusfunc=Thesaur
|
||||
endif
|
||||
|
||||
|
||||
Completing keywords in the current and included files *compl-keyword*
|
||||
@@ -1949,6 +1947,9 @@ When 'autoindent' is on, the indent for a new line is obtained from the
|
||||
previous line. When 'smartindent' or 'cindent' is on, the indent for a line
|
||||
is automatically adjusted for C programs.
|
||||
|
||||
'formatoptions' can be set to copy the comment leader when opening a new
|
||||
line.
|
||||
|
||||
'textwidth' can be set to the maximum width for a line. When a line becomes
|
||||
too long when appending characters a line break is automatically inserted.
|
||||
|
||||
@@ -1962,6 +1963,9 @@ too long when appending characters a line break is automatically inserted.
|
||||
inserted after the current line.
|
||||
Adding [!] toggles 'autoindent' for the time this
|
||||
command is executed.
|
||||
This command is not supported in |Vim9| script,
|
||||
because it is too easily confused with a variable
|
||||
name.
|
||||
|
||||
*:i* *:in* *:insert*
|
||||
:{range}i[nsert][!] Insert several lines of text above the specified
|
||||
@@ -1969,6 +1973,9 @@ too long when appending characters a line break is automatically inserted.
|
||||
inserted before the current line.
|
||||
Adding [!] toggles 'autoindent' for the time this
|
||||
command is executed.
|
||||
This command is not supported in |Vim9| script,
|
||||
because it is too easily confused with a variable
|
||||
name.
|
||||
|
||||
These two commands will keep on asking for lines, until you type a line
|
||||
containing only a ".". Watch out for lines starting with a backslash, see
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*map.txt* For Vim version 8.2. Last change: 2021 Sep 12
|
||||
*map.txt* For Vim version 8.2. Last change: 2021 Dec 24
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -61,6 +61,8 @@ modes.
|
||||
where the map command applies. The result, including
|
||||
{rhs}, is then further scanned for mappings. This
|
||||
allows for nested and recursive use of mappings.
|
||||
Note: Trailing spaces are included in the {rhs},
|
||||
because space is a valid Normal mode command.
|
||||
|
||||
*:nore* *:norem*
|
||||
:no[remap] {lhs} {rhs} |mapmode-nvo| *:no* *:noremap* *:nor*
|
||||
@@ -94,6 +96,9 @@ modes.
|
||||
Remove the mapping of {lhs} for the modes where the
|
||||
map command applies. The mapping may remain defined
|
||||
for other modes where it applies.
|
||||
It also works when {lhs} matches the {rhs} of a
|
||||
mapping. This is for when when an abbreviation
|
||||
applied.
|
||||
Note: Trailing spaces are included in the {lhs}. This
|
||||
unmap does NOT work: >
|
||||
:map @@ foo
|
||||
@@ -168,7 +173,7 @@ type "a", then "bar" will get inserted.
|
||||
"<unique>" can be used in any order. They must appear right after the
|
||||
command, before any other arguments.
|
||||
|
||||
*:map-local* *:map-<buffer>* *E224* *E225*
|
||||
*:map-local* *:map-<buffer>* *:map-buffer* *E224* *E225*
|
||||
If the first argument to one of these commands is "<buffer>" the mapping will
|
||||
be effective in the current buffer only. Example: >
|
||||
:map <buffer> ,w /[.,;]<CR>
|
||||
@@ -227,7 +232,7 @@ Note: ":map <script>" and ":noremap <script>" do the same thing. The
|
||||
"<script>" overrules the command name. Using ":noremap <script>" is
|
||||
preferred, because it's clearer that remapping is (mostly) disabled.
|
||||
|
||||
*:map-<unique>* *E226* *E227*
|
||||
*:map-<unique>* *:map-unique* *E226* *E227*
|
||||
If the first argument to one of these commands is "<unique>" and it is used to
|
||||
define a new mapping or abbreviation, the command will fail if the mapping or
|
||||
abbreviation already exists. Example: >
|
||||
@@ -344,12 +349,14 @@ Note:
|
||||
- For the same reason, |keycodes| like <C-R><C-W> are interpreted as plain,
|
||||
unmapped keys.
|
||||
- The command is not echo'ed, no need for <silent>.
|
||||
- The {rhs} is not subject to abbreviations nor to other mappings, even if the
|
||||
mapping is recursive.
|
||||
- In Visual mode you can use `line('v')` and `col('v')` to get one end of the
|
||||
Visual area, the cursor is at the other end.
|
||||
- In Select mode, |:map| and |:vmap| command mappings are executed in
|
||||
Visual mode. Use |:smap| to handle Select mode differently.
|
||||
|
||||
*E1135* *E1136*
|
||||
*E1255* *E1136*
|
||||
<Cmd> commands must terminate, that is, they must be followed by <CR> in the
|
||||
{rhs} of the mapping definition. |Command-line| mode is never entered.
|
||||
|
||||
@@ -955,8 +962,7 @@ g@{motion} Call the function set by the 'operatorfunc' option.
|
||||
"line" {motion} was |linewise|
|
||||
"char" {motion} was |characterwise|
|
||||
"block" {motion} was |blockwise-visual|
|
||||
Although "block" would rarely appear, since it can
|
||||
only result from Visual mode where "g@" is not useful.
|
||||
The type can be forced, see |forced-motion|.
|
||||
{not available when compiled without the |+eval|
|
||||
feature}
|
||||
|
||||
@@ -967,28 +973,56 @@ Here is an example that counts the number of spaces with <F4>: >
|
||||
" doubling <F4> works on a line
|
||||
nnoremap <expr> <F4><F4> CountSpaces() .. '_'
|
||||
|
||||
function CountSpaces(type = '') abort
|
||||
function CountSpaces(context = {}, type = '') abort
|
||||
if a:type == ''
|
||||
set opfunc=CountSpaces
|
||||
let context = #{
|
||||
\ dot_command: v:false,
|
||||
\ extend_block: '',
|
||||
\ virtualedit: [&l:virtualedit, &g:virtualedit],
|
||||
\ }
|
||||
let &operatorfunc = function('CountSpaces', [context])
|
||||
set virtualedit=block
|
||||
return 'g@'
|
||||
endif
|
||||
endif
|
||||
|
||||
let sel_save = &selection
|
||||
let reg_save = getreginfo('"')
|
||||
let cb_save = &clipboard
|
||||
let visual_marks_save = [getpos("'<"), getpos("'>")]
|
||||
let save = #{
|
||||
\ clipboard: &clipboard,
|
||||
\ selection: &selection,
|
||||
\ virtualedit: [&l:virtualedit, &g:virtualedit],
|
||||
\ register: getreginfo('"'),
|
||||
\ visual_marks: [getpos("'<"), getpos("'>")],
|
||||
\ }
|
||||
|
||||
try
|
||||
set clipboard= selection=inclusive
|
||||
let commands = #{line: "'[V']y", char: "`[v`]y", block: "`[\<c-v>`]y"}
|
||||
silent exe 'noautocmd keepjumps normal! ' .. get(commands, a:type, '')
|
||||
echom getreg('"')->count(' ')
|
||||
set clipboard= selection=inclusive virtualedit=
|
||||
let commands = #{
|
||||
\ line: "'[V']",
|
||||
\ char: "`[v`]",
|
||||
\ block: "`[\<C-V>`]",
|
||||
\ }[a:type]
|
||||
let [_, _, col, off] = getpos("']")
|
||||
if off != 0
|
||||
let vcol = getline("'[")->strpart(0, col + off)->strdisplaywidth()
|
||||
if vcol >= [line("'["), '$']->virtcol() - 1
|
||||
let a:context.extend_block = '$'
|
||||
else
|
||||
let a:context.extend_block = vcol .. '|'
|
||||
endif
|
||||
endif
|
||||
if a:context.extend_block != ''
|
||||
let commands ..= 'oO' .. a:context.extend_block
|
||||
endif
|
||||
let commands ..= 'y'
|
||||
execute 'silent noautocmd keepjumps normal! ' .. commands
|
||||
echomsg getreg('"')->count(' ')
|
||||
finally
|
||||
call setreg('"', reg_save)
|
||||
call setpos("'<", visual_marks_save[0])
|
||||
call setpos("'>", visual_marks_save[1])
|
||||
let &clipboard = cb_save
|
||||
let &selection = sel_save
|
||||
call setreg('"', save.register)
|
||||
call setpos("'<", save.visual_marks[0])
|
||||
call setpos("'>", save.visual_marks[1])
|
||||
let &clipboard = save.clipboard
|
||||
let &selection = save.selection
|
||||
let [&l:virtualedit, &g:virtualedit] = get(a:context.dot_command ? save : a:context, 'virtualedit')
|
||||
let a:context.dot_command = v:true
|
||||
endtry
|
||||
endfunction
|
||||
|
||||
@@ -1004,6 +1038,20 @@ Also note that the 'clipboard' option is temporarily emptied to avoid
|
||||
clobbering the `"*` or `"+` registers, if its value contains the item `unnamed`
|
||||
or `unnamedplus`.
|
||||
|
||||
The `mode()` function will return the state as it will be after applying the
|
||||
operator.
|
||||
|
||||
Here is an example for using a lambda function to create a normal-mode
|
||||
operator to add quotes around text in the current line: >
|
||||
|
||||
nnoremap <F4> <Cmd>let &opfunc='{t ->
|
||||
\ getline(".")
|
||||
\ ->split("\\zs")
|
||||
\ ->insert("\"", col("'']"))
|
||||
\ ->insert("\"", col("''[") - 1)
|
||||
\ ->join("")
|
||||
\ ->setline(".")}'<CR>g@
|
||||
|
||||
==============================================================================
|
||||
2. Abbreviations *abbreviations* *Abbreviations*
|
||||
|
||||
@@ -1557,6 +1605,7 @@ Possible values are (second column is the short name used in listing):
|
||||
Special cases ~
|
||||
*:command-bang* *:command-bar*
|
||||
*:command-register* *:command-buffer*
|
||||
*:command-keepscript*
|
||||
There are some special cases as well:
|
||||
|
||||
-bang The command can take a ! modifier (like :q or :w)
|
||||
@@ -1566,6 +1615,9 @@ There are some special cases as well:
|
||||
-register The first argument to the command can be an optional
|
||||
register name (like :del, :put, :yank).
|
||||
-buffer The command will only be available in the current buffer.
|
||||
-keepscript Do not use the location of where the user command was
|
||||
defined for verbose messages, use the location of where
|
||||
the user command was invoked.
|
||||
|
||||
In the cases of the -count and -register attributes, if the optional argument
|
||||
is supplied, it is removed from the argument list and is available to the
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*message.txt* For Vim version 8.2. Last change: 2021 Jul 31
|
||||
*message.txt* For Vim version 8.2. Last change: 2021 Dec 13
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -29,8 +29,7 @@ depends on the 'shortmess' option.
|
||||
Clear messages, keeping only the {count} most
|
||||
recent ones.
|
||||
|
||||
The number of remembered messages is fixed at 20 for the tiny version and 200
|
||||
for other versions.
|
||||
The number of remembered messages is fixed at 200.
|
||||
|
||||
*g<*
|
||||
The "g<" command can be used to see the last page of previous command output.
|
||||
@@ -141,6 +140,11 @@ larger. When it's more there probably is an endless loop. Probably a
|
||||
The color name {name} is unknown. See |gui-colors| for a list of colors that
|
||||
are available on most systems.
|
||||
|
||||
*E1244* >
|
||||
Bad color string: {str}
|
||||
|
||||
The provided color did not conform to the pattern #rrggbb
|
||||
|
||||
*E458* >
|
||||
Cannot allocate colormap entry, some colors may be incorrect
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*motion.txt* For Vim version 8.2. Last change: 2021 Jun 13
|
||||
*motion.txt* For Vim version 8.2. Last change: 2021 Dec 27
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -386,6 +386,8 @@ w [count] words forward. |exclusive| motion.
|
||||
|
||||
<C-Right> or *<C-Right>* *W*
|
||||
W [count] WORDS forward. |exclusive| motion.
|
||||
If <C-Right> does not work, check out
|
||||
|arrow_modifiers|.
|
||||
|
||||
*e*
|
||||
e Forward to the end of word [count] |inclusive|.
|
||||
@@ -400,6 +402,8 @@ b [count] words backward. |exclusive| motion.
|
||||
|
||||
<C-Left> or *<C-Left>* *B*
|
||||
B [count] WORDS backward. |exclusive| motion.
|
||||
If <C-Left> does not work, check out
|
||||
|arrow_modifiers|.
|
||||
|
||||
*ge*
|
||||
ge Backward to the end of word [count] |inclusive|.
|
||||
@@ -784,6 +788,9 @@ m< or m> Set the |'<| or |'>| mark. Useful to change what the
|
||||
*:k*
|
||||
:[range]k{a-zA-Z'} Same as :mark, but the space before the mark name can
|
||||
be omitted.
|
||||
This command is not supported in |Vim9| script,
|
||||
because it is too easily confused with a variable
|
||||
name.
|
||||
|
||||
*'* *'a* *`* *`a*
|
||||
'{a-z} `{a-z} Jump to the mark {a-z} in the current buffer.
|
||||
@@ -1034,12 +1041,10 @@ commands that start editing a new file.
|
||||
*CTRL-O*
|
||||
CTRL-O Go to [count] Older cursor position in jump list
|
||||
(not a motion command).
|
||||
{not available without the |+jumplist| feature}
|
||||
|
||||
<Tab> or *CTRL-I* *<Tab>*
|
||||
CTRL-I Go to [count] newer cursor position in jump list
|
||||
(not a motion command).
|
||||
{not available without the |+jumplist| feature}
|
||||
|
||||
NOTE: In the GUI and in a terminal supporting
|
||||
|modifyOtherKeys|, CTRL-I can be mapped separately
|
||||
@@ -1049,18 +1054,15 @@ CTRL-I Go to [count] newer cursor position in jump list
|
||||
|
||||
*:ju* *:jumps*
|
||||
:ju[mps] Print the jump list (not a motion command).
|
||||
{not available without the |+jumplist| feature}
|
||||
|
||||
*:cle* *:clearjumps*
|
||||
:cle[arjumps] Clear the jump list of the current window.
|
||||
{not available without the |+jumplist| feature}
|
||||
|
||||
*jumplist*
|
||||
Jumps are remembered in a jump list. With the CTRL-O and CTRL-I command you
|
||||
can go to cursor positions before older jumps, and back again. Thus you can
|
||||
move up and down the list. There is a separate jump list for each window.
|
||||
The maximum number of entries is fixed at 100.
|
||||
{not available without the |+jumplist| feature}
|
||||
|
||||
For example, after three jump commands you have this jump list:
|
||||
|
||||
@@ -1137,13 +1139,11 @@ g; Go to [count] older position in change list.
|
||||
positions go to the oldest change.
|
||||
If there is no older change an error message is given.
|
||||
(not a motion command)
|
||||
{not available without the |+jumplist| feature}
|
||||
|
||||
*g,* *E663*
|
||||
g, Go to [count] newer cursor position in change list.
|
||||
Just like |g;| but in the opposite direction.
|
||||
(not a motion command)
|
||||
{not available without the |+jumplist| feature}
|
||||
|
||||
When using a count you jump as far back or forward as possible. Thus you can
|
||||
use "999g;" to go to the first change for which the position is still
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*options.txt* For Vim version 8.2. Last change: 2021 Sep 21
|
||||
*options.txt* For Vim version 8.2. Last change: 2021 Dec 26
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -35,6 +35,8 @@ achieve special effects. These options come in three forms:
|
||||
internally and can't be changed. Changing the terminal
|
||||
codes in the GUI is not useful either...
|
||||
|
||||
:se[t]! termcap Idem, but don't use multiple columns.
|
||||
|
||||
*E518* *E519*
|
||||
:se[t] {option}? Show value of {option}.
|
||||
|
||||
@@ -371,6 +373,30 @@ Note: In the future more global options can be made global-local. Using
|
||||
":setlocal" on a global option might work differently then.
|
||||
|
||||
|
||||
*option-value-function*
|
||||
Some options ('completefunc', 'imactivatefunc', 'imstatusfunc', 'omnifunc',
|
||||
'operatorfunc', 'quickfixtextfunc', 'tagfunc' and 'thesaurusfunc') are set to
|
||||
a function name or a function reference or a lambda function. When using a
|
||||
lambda it will be converted to the name, e.g. "<lambda>123". Examples:
|
||||
>
|
||||
set opfunc=MyOpFunc
|
||||
set opfunc=function('MyOpFunc')
|
||||
set opfunc=funcref('MyOpFunc')
|
||||
set opfunc={a\ ->\ MyOpFunc(a)}
|
||||
" set using a funcref variable
|
||||
let Fn = function('MyTagFunc')
|
||||
let &tagfunc = Fn
|
||||
" set using a lambda expression
|
||||
let &tagfunc = {t -> MyTagFunc(t)}
|
||||
" set using a variable with lambda expression
|
||||
let L = {a, b, c -> MyTagFunc(a, b , c)}
|
||||
let &tagfunc = L
|
||||
|
||||
In Vim9 script, in a compiled function, you can use a lambda, but a
|
||||
closured does not work, because the function will be called without the
|
||||
context of where it was defined.
|
||||
|
||||
|
||||
Setting the filetype
|
||||
|
||||
:setf[iletype] [FALLBACK] {filetype} *:setf* *:setfiletype*
|
||||
@@ -717,7 +743,8 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
"double": Use twice the width of ASCII characters.
|
||||
*E834* *E835*
|
||||
The value "double" cannot be used if 'listchars' or 'fillchars'
|
||||
contains a character that would be double width.
|
||||
contains a character that would be double width. These errors may
|
||||
also be given when calling setcellwidths().
|
||||
|
||||
The values are overruled for characters specified with
|
||||
|setcellwidths()|.
|
||||
@@ -849,9 +876,12 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
'autowrite' 'aw' boolean (default off)
|
||||
global
|
||||
Write the contents of the file, if it has been modified, on each
|
||||
:next, :rewind, :last, :first, :previous, :stop, :suspend, :tag, :!,
|
||||
:make, CTRL-] and CTRL-^ command; and when a :buffer, CTRL-O, CTRL-I,
|
||||
'{A-Z0-9}, or `{A-Z0-9} command takes one to another file.
|
||||
`:next`, `:rewind`, `:last`, `:first`, `:previous`, `:stop`,
|
||||
`:suspend`, `:tag, `:!`, ``:make`, CTRL-] and CTRL-^ command; and when
|
||||
a :buffer, CTRL-O, CTRL-I, '{A-Z0-9}, or `{A-Z0-9} command takes one
|
||||
to another file.
|
||||
A buffer is not written if it becomes hidden, e.g. when 'bufhidden' is
|
||||
set to "hide" and `:next` is used
|
||||
Note that for some commands the 'autowrite' option is not used, see
|
||||
'autowriteall' for that.
|
||||
Some buffers will not be written, specifically when 'buftype' is
|
||||
@@ -1195,6 +1225,11 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
Vim does not try to send a message to an external debugger (Netbeans
|
||||
or Sun Workshop).
|
||||
|
||||
If the expression starts with s: or |<SID>|, then it is replaced with
|
||||
the script ID (|local-function|). Example: >
|
||||
set bexpr=s:MyBalloonExpr()
|
||||
set bexpr=<SID>SomeBalloonExpr()
|
||||
<
|
||||
The expression will be evaluated in the |sandbox| when set from a
|
||||
modeline, see |sandbox-option|.
|
||||
This option cannot be set in a modeline when 'modelineexpr' is off.
|
||||
@@ -1419,6 +1454,8 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
Also see |win_gettype()|, which returns the type of the window.
|
||||
|
||||
Be careful with changing this option, it can have many side effects!
|
||||
One such effect is that Vim will not check the timestamp of the file,
|
||||
if the file is changed by another program this will not be noticed.
|
||||
|
||||
A "quickfix" buffer is only used for the error list and the location
|
||||
list. This value is set by the |:cwindow| and |:lwindow| commands and
|
||||
@@ -1461,6 +1498,15 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
case mapping, the current locale is not effective.
|
||||
This probably only matters for Turkish.
|
||||
|
||||
*'cdhome'* *'cdh'*
|
||||
'cdhome' 'cdh' boolean (default: off)
|
||||
global
|
||||
When on, |:cd|, |:tcd| and |:lcd| without an argument changes the
|
||||
current working directory to the |$HOME| directory like in Unix.
|
||||
When off, those commands just print the current directory name.
|
||||
On Unix this option has no effect.
|
||||
NOTE: This option is reset when 'compatible' is set.
|
||||
|
||||
*'cdpath'* *'cd'* *E344* *E346*
|
||||
'cdpath' 'cd' string (default: equivalent to $CDPATH or ",,")
|
||||
global
|
||||
@@ -1802,6 +1848,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
'balloonexpr' + "" text to show in evaluation balloon
|
||||
'breakindent' + off don't indent when wrapping lines
|
||||
'cedit' - {unchanged} {set vim default only on resetting 'cp'}
|
||||
'cdhome' + off ":cd" don't chdir to home on non-Unix
|
||||
'cindent' + off no C code indentation
|
||||
'compatible' - {unchanged} {set vim default only on resetting 'cp'}
|
||||
'copyindent' + off don't copy indent structure
|
||||
@@ -1917,7 +1964,9 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
This option specifies a function to be used for Insert mode completion
|
||||
with CTRL-X CTRL-U. |i_CTRL-X_CTRL-U|
|
||||
See |complete-functions| for an explanation of how the function is
|
||||
invoked and what it should return.
|
||||
invoked and what it should return. The value can be the name of a
|
||||
function, a |lambda| or a |Funcref|. See |option-value-function| for
|
||||
more information.
|
||||
This option cannot be set from a |modeline| or in the |sandbox|, for
|
||||
security reasons.
|
||||
|
||||
@@ -2084,8 +2133,18 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
Commas can be added for readability.
|
||||
To avoid problems with flags that are added in the future, use the
|
||||
"+=" and "-=" feature of ":set" |add-option-flags|.
|
||||
|
||||
NOTE: This option is set to the Vi default value when 'compatible' is
|
||||
set and to the Vim default value when 'compatible' is reset.
|
||||
|
||||
NOTE: In a |Vim9| script, when `vim9script` is encountered, the value
|
||||
is saved, 'cpoptions' is set to the Vim default, and the saved value
|
||||
is restored at the end of the script. Changes to the value of
|
||||
'cpoptions' will be applied to the saved value, but keep in mind that
|
||||
removing a flag that is not present when 'cpoptions' is changed has no
|
||||
effect. In the |.vimrc| file the value is not restored, thus using
|
||||
`vim9script` in the |.vimrc| file results in using the Vim default.
|
||||
|
||||
NOTE: This option is set to the POSIX default value at startup when
|
||||
the Vi default value would be used and the $VIM_POSIX environment
|
||||
variable exists |posix|. This means Vim tries to behave like the
|
||||
@@ -3552,6 +3611,11 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
When the expression evaluates to non-zero Vim will fall back to using
|
||||
the internal format mechanism.
|
||||
|
||||
If the expression starts with s: or |<SID>|, then it is replaced with
|
||||
the script ID (|local-function|). Example: >
|
||||
set formatexpr=s:MyFormatExpr()
|
||||
set formatexpr=<SID>SomeFormatExpr()
|
||||
<
|
||||
The expression will be evaluated in the |sandbox| when set from a
|
||||
modeline, see |sandbox-option|. That stops the option from working,
|
||||
since changing the buffer text is not allowed.
|
||||
@@ -4176,8 +4240,6 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
*'icon'* *'noicon'*
|
||||
'icon' boolean (default off, on when title can be restored)
|
||||
global
|
||||
{not available when compiled without the |+title|
|
||||
feature}
|
||||
When on, the icon text of the window will be set to the value of
|
||||
'iconstring' (if it is not empty), or to the name of the file
|
||||
currently being edited. Only the last part of the name is used.
|
||||
@@ -4194,8 +4256,6 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
*'iconstring'*
|
||||
'iconstring' string (default "")
|
||||
global
|
||||
{not available when compiled without the |+title|
|
||||
feature}
|
||||
When this option is not empty, it will be used for the icon text of
|
||||
the window. This happens only when the 'icon' option is on.
|
||||
Only works if the terminal supports setting window icon text
|
||||
@@ -4222,7 +4282,9 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
'imactivatefunc' 'imaf' string (default "")
|
||||
global
|
||||
This option specifies a function that will be called to
|
||||
activate or deactivate the Input Method.
|
||||
activate or deactivate the Input Method. The value can be the name of
|
||||
a function, a |lambda| or a |Funcref|. See |option-value-function| for
|
||||
more information.
|
||||
It is not used in the MS-Windows GUI version.
|
||||
The expression will be evaluated in the |sandbox| when set from a
|
||||
modeline, see |sandbox-option|.
|
||||
@@ -4332,6 +4394,8 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
global
|
||||
This option specifies a function that is called to obtain the status
|
||||
of Input Method. It must return a positive number when IME is active.
|
||||
The value can be the name of a function, a |lambda| or a |Funcref|.
|
||||
See |option-value-function| for more information.
|
||||
It is not used in the MS-Windows GUI version.
|
||||
|
||||
Example: >
|
||||
@@ -4394,6 +4458,11 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
found. Allows doing "gf" on the name after an 'include' statement.
|
||||
Also used for |<cfile>|.
|
||||
|
||||
If the expression starts with s: or |<SID>|, then it is replaced with
|
||||
the script ID (|local-function|). Example: >
|
||||
set includeexpr=s:MyIncludeExpr(v:fname)
|
||||
set includeexpr=<SID>SomeIncludeExpr(v:fname)
|
||||
<
|
||||
The expression will be evaluated in the |sandbox| when set from a
|
||||
modeline, see |sandbox-option|.
|
||||
This option cannot be set in a modeline when 'modelineexpr' is off.
|
||||
@@ -4467,6 +4536,11 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
The expression is evaluated with |v:lnum| set to the line number for
|
||||
which the indent is to be computed. The cursor is also in this line
|
||||
when the expression is evaluated (but it may be moved around).
|
||||
If the expression starts with s: or |<SID>|, then it is replaced with
|
||||
the script ID (|local-function|). Example: >
|
||||
set indentexpr=s:MyIndentExpr()
|
||||
set indentexpr=<SID>SomeIndentExpr()
|
||||
<
|
||||
The expression must return the number of spaces worth of indent. It
|
||||
can return "-1" to keep the current indent (this means 'autoindent' is
|
||||
used for the indent).
|
||||
@@ -4905,9 +4979,10 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
*'list'* *'nolist'*
|
||||
'list' boolean (default off)
|
||||
local to window
|
||||
List mode: Show tabs as CTRL-I is displayed, display $ after end of
|
||||
line. Useful to see the difference between tabs and spaces and for
|
||||
trailing blanks. Further changed by the 'listchars' option.
|
||||
List mode: By default show tabs as CTRL-I is displayed, display $
|
||||
after end of line. Useful to see the difference between tabs and
|
||||
spaces and for trailing blanks. Further changed by the 'listchars'
|
||||
option.
|
||||
|
||||
The cursor is displayed at the start of the space a Tab character
|
||||
occupies, not at the end as usual in Normal mode. To get this cursor
|
||||
@@ -5556,8 +5631,8 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
number.
|
||||
When a long, wrapped line doesn't start with the first character, '-'
|
||||
characters are put before the number.
|
||||
See |hl-LineNr| and |hl-CursorLineNr| for the highlighting used for
|
||||
the number.
|
||||
For highlighting see |hl-LineNr|, and |hl-CursorLineNr|, and the
|
||||
|:sign-define| "numhl" argument.
|
||||
*number_relativenumber*
|
||||
The 'relativenumber' option changes the displayed number to be
|
||||
relative to the cursor. Together with 'number' there are these
|
||||
@@ -5597,7 +5672,9 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
This option specifies a function to be used for Insert mode omni
|
||||
completion with CTRL-X CTRL-O. |i_CTRL-X_CTRL-O|
|
||||
See |complete-functions| for an explanation of how the function is
|
||||
invoked and what it should return.
|
||||
invoked and what it should return. The value can be the name of a
|
||||
function, a |lambda| or a |Funcref|. See |option-value-function| for
|
||||
more information.
|
||||
This option is usually set by a filetype plugin:
|
||||
|:filetype-plugin-on|
|
||||
This option cannot be set from a |modeline| or in the |sandbox|, for
|
||||
@@ -5619,7 +5696,9 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
'operatorfunc' 'opfunc' string (default: empty)
|
||||
global
|
||||
This option specifies a function to be called by the |g@| operator.
|
||||
See |:map-operator| for more info and an example.
|
||||
See |:map-operator| for more info and an example. The value can be
|
||||
the name of a function, a |lambda| or a |Funcref|. See
|
||||
|option-value-function| for more information.
|
||||
|
||||
This option cannot be set from a |modeline| or in the |sandbox|, for
|
||||
security reasons.
|
||||
@@ -6019,8 +6098,9 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
customize the information displayed in the quickfix or location window
|
||||
for each entry in the corresponding quickfix or location list. See
|
||||
|quickfix-window-function| for an explanation of how to write the
|
||||
function and an example. The value can be the name of a function or a
|
||||
lambda.
|
||||
function and an example. The value can be the name of a function, a
|
||||
|lambda| or a |Funcref|. See |option-value-function| for more
|
||||
information.
|
||||
|
||||
This option cannot be set from a |modeline| or in the |sandbox|, for
|
||||
security reasons.
|
||||
@@ -7774,7 +7854,9 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
This option specifies a function to be used to perform tag searches.
|
||||
The function gets the tag pattern and should return a List of matching
|
||||
tags. See |tag-function| for an explanation of how to write the
|
||||
function and an example.
|
||||
function and an example. The value can be the name of a function, a
|
||||
|lambda| or a |Funcref|. See |option-value-function| for more
|
||||
information.
|
||||
|
||||
*'taglength'* *'tl'*
|
||||
'taglength' 'tl' number (default 0)
|
||||
@@ -7937,6 +8019,9 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
Number of scrollback lines to keep. When going over this limit the
|
||||
first 10% of the scrollback lines are deleted. This is just to reduce
|
||||
the memory usage. See |Terminal-Normal|.
|
||||
Also used as a limit for text sent to the terminal in one write,
|
||||
multiplied by the number of columns times 3 (average number of bytes
|
||||
per cell).
|
||||
|
||||
*'termwinsize'* *'tws'*
|
||||
'termwinsize' 'tws' string (default "")
|
||||
@@ -8048,6 +8133,8 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
feature}
|
||||
This option specifies a function to be used for thesaurus completion
|
||||
with CTRL-X CTRL-T. |i_CTRL-X_CTRL-T| See |compl-thesaurusfunc|.
|
||||
The value can be the name of a function, a |lambda| or a |Funcref|.
|
||||
See |option-value-function| for more information.
|
||||
|
||||
This option cannot be set from a |modeline| or in the |sandbox|, for
|
||||
security reasons.
|
||||
@@ -8118,8 +8205,6 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
*'title'* *'notitle'*
|
||||
'title' boolean (default off, on when title can be restored)
|
||||
global
|
||||
{not available when compiled without the |+title|
|
||||
feature}
|
||||
When on, the title of the window will be set to the value of
|
||||
'titlestring' (if it is not empty), or to:
|
||||
filename [+=-] (path) - VIM
|
||||
@@ -8153,8 +8238,6 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
*'titlelen'*
|
||||
'titlelen' number (default 85)
|
||||
global
|
||||
{not available when compiled without the |+title|
|
||||
feature}
|
||||
Gives the percentage of 'columns' to use for the length of the window
|
||||
title. When the title is longer, only the end of the path name is
|
||||
shown. A '<' character before the path name is used to indicate this.
|
||||
@@ -8168,8 +8251,6 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
*'titleold'*
|
||||
'titleold' string (default "Thanks for flying Vim")
|
||||
global
|
||||
{only available when compiled with the |+title|
|
||||
feature}
|
||||
This option will be used for the window title when exiting Vim if the
|
||||
original title cannot be restored. Only happens if 'title' is on or
|
||||
'titlestring' is not empty.
|
||||
@@ -8178,8 +8259,6 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
*'titlestring'*
|
||||
'titlestring' string (default "")
|
||||
global
|
||||
{not available when compiled without the |+title|
|
||||
feature}
|
||||
When this option is not empty, it will be used for the title of the
|
||||
window. This happens only when the 'title' option is on.
|
||||
Only works if the terminal supports setting window titles (currently
|
||||
@@ -9157,4 +9236,16 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
screen. When non-zero, characters are sent to the terminal one by
|
||||
one. For debugging purposes.
|
||||
|
||||
*'xtermcodes'* *'noxtermcodes'*
|
||||
'xtermcodes' boolean (default on)
|
||||
global
|
||||
When detecting xterm patchlevel 141 or higher with the termresponse
|
||||
mechanism and this option is set, Vim will request the actual terminal
|
||||
key codes and number of colors from the terminal. This takes care of
|
||||
various configuration options of the terminal that cannot be obtained
|
||||
from the termlib/terminfo entry, see |xterm-codes|.
|
||||
A side effect may be that t_Co changes and Vim will redraw the
|
||||
display.
|
||||
|
||||
|
||||
vim:tw=78:ts=8:noet:ft=help:norl:
|
||||
|
||||
@@ -194,9 +194,8 @@ $VIM/macros/swapmous.vim for an example. |gui-mouse-mapping|
|
||||
|
||||
11. Color names *haiku-colors*
|
||||
|
||||
Vim has a number of color names built-in. Additional names are read from the
|
||||
file $VIMRUNTIME/rgb.txt, if present. This file is basically the color
|
||||
database from X. Names used from this file are cached for efficiency.
|
||||
Vim has a number of color names built-in. Additional names can be defined in
|
||||
|v:colornames|. See |:colorscheme| for details.
|
||||
|
||||
|
||||
12. GUI Toolbar Images *haiku-toolbar-images*
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*pi_zip.txt* For Vim version 8.2. Last change: 2020 Jan 07
|
||||
*pi_zip.txt* For Vim version 8.2. Last change: 2021 Nov 08
|
||||
|
||||
+====================+
|
||||
| Zip File Interface |
|
||||
@@ -102,6 +102,9 @@ Copyright: Copyright (C) 2005-2015 Charles E Campbell *zip-copyright*
|
||||
|
||||
==============================================================================
|
||||
4. History *zip-history* {{{1
|
||||
v32 Oct 22, 2021 * to avoid an issue with a vim 8.2 patch, zipfile: has
|
||||
been changed to zipfile:// . This often shows up
|
||||
as zipfile:/// with zipped files that are root-based.
|
||||
v29 Apr 02, 2017 * (Klartext) reported that an encrypted zip file could
|
||||
opened but the swapfile held unencrypted contents.
|
||||
The solution is to edit the contents of a zip file
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*popup.txt* For Vim version 8.2. Last change: 2021 Aug 15
|
||||
*popup.txt* For Vim version 8.2. Last change: 2021 Nov 29
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -681,6 +681,9 @@ The second argument of |popup_create()| is a dictionary with options:
|
||||
popup does not have a border. As soon as dragging
|
||||
starts and "pos" is "center" it is changed to
|
||||
"topleft".
|
||||
dragall TRUE to allow the popup to be dragged from every
|
||||
position. Makes it very difficult to select text in
|
||||
the popup.
|
||||
resize TRUE to allow the popup to be resized with the mouse
|
||||
by grabbing at the bottom right corner. Has no effect
|
||||
if the popup does not have a border.
|
||||
|
||||
@@ -174,6 +174,11 @@ an error message. In that case Vim will delete the file. In the default
|
||||
value for non-MS-Windows a trick is used: Adding "v:shell_error" will result
|
||||
in a non-zero number when the system() call fails.
|
||||
|
||||
If the expression starts with s: or |<SID>|, then it is replaced with the
|
||||
script ID (|local-function|). Example: >
|
||||
set printexpr=s:MyPrintFile()
|
||||
set printexpr=<SID>SomePrintFile()
|
||||
<
|
||||
This option cannot be set from a |modeline| or in the |sandbox|, for security
|
||||
reasons.
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*quickfix.txt* For Vim version 8.2. Last change: 2021 May 22
|
||||
*quickfix.txt* For Vim version 8.2. Last change: 2021 Dec 03
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -856,9 +856,9 @@ lists. They set one of the existing error lists as the current one.
|
||||
*:chistory* *:chi*
|
||||
:[count]chi[story] Show the list of error lists. The current list is
|
||||
marked with ">". The output looks like:
|
||||
error list 1 of 3; 43 errors ~
|
||||
> error list 2 of 3; 0 errors ~
|
||||
error list 3 of 3; 15 errors ~
|
||||
error list 1 of 3; 43 errors :make ~
|
||||
> error list 2 of 3; 0 errors :helpgrep tag ~
|
||||
error list 3 of 3; 15 errors :grep ex_help *.c ~
|
||||
|
||||
When [count] is given, then the count'th quickfix
|
||||
list is made the current list. Example: >
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*quickref.txt* For Vim version 8.2. Last change: 2021 Mar 29
|
||||
*quickref.txt* For Vim version 8.2. Last change: 2021 Dec 21
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -635,6 +635,7 @@ Short explanation of each option: *option-list*
|
||||
'buflisted' 'bl' whether the buffer shows up in the buffer list
|
||||
'buftype' 'bt' special type of buffer
|
||||
'casemap' 'cmp' specifies how case of letters is changed
|
||||
'cdhome' 'cdh' change directory to the home directory by ":cd"
|
||||
'cdpath' 'cd' list of directories searched with ":cd"
|
||||
'cedit' key used to open the command-line window
|
||||
'charconvert' 'ccv' expression for character encoding conversion
|
||||
@@ -732,6 +733,7 @@ Short explanation of each option: *option-list*
|
||||
'guifontset' 'gfs' GUI: Names of multibyte fonts to be used
|
||||
'guifontwide' 'gfw' list of font names for double-wide characters
|
||||
'guiheadroom' 'ghr' GUI: pixels room for window decorations
|
||||
'guiligatures' 'gli' GTK GUI: ASCII characters that can form shapes
|
||||
'guioptions' 'go' GUI: Which components and options are used
|
||||
'guipty' GUI: try to use a pseudo-tty for ":!" commands
|
||||
'guitablabel' 'gtl' GUI: custom label for a tab page
|
||||
@@ -1008,6 +1010,7 @@ Short explanation of each option: *option-list*
|
||||
'writeany' 'wa' write to file with no need for "!" override
|
||||
'writebackup' 'wb' make a backup before overwriting a file
|
||||
'writedelay' 'wd' delay this many msec for each char (for debug)
|
||||
'xtermcodes' request terminal codes from an xterm
|
||||
------------------------------------------------------------------------------
|
||||
*Q_ur* Undo/Redo commands
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*remote.txt* For Vim version 8.2. Last change: 2019 May 05
|
||||
*remote.txt* For Vim version 8.2. Last change: 2021 Dec 27
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -143,7 +143,7 @@ You can not put options there!
|
||||
FUNCTIONS
|
||||
*E240* *E573*
|
||||
There are a number of Vim functions for scripting the command server. See
|
||||
the description in |eval.txt| or use CTRL-] on the function name to jump to
|
||||
the description in |builtin.txt| or use CTRL-] on the function name to jump to
|
||||
the full explanation.
|
||||
|
||||
synopsis explanation ~
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*repeat.txt* For Vim version 8.2. Last change: 2021 Sep 09
|
||||
*repeat.txt* For Vim version 8.2. Last change: 2021 Dec 27
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -495,6 +495,9 @@ space at the end of a line is hard to see and may be accidentally deleted. >
|
||||
\ "very long regexp"
|
||||
\ keepend
|
||||
|
||||
In |Vim9| script the backslash can often be omitted, but not always.
|
||||
See |vim9-line-continuation|.
|
||||
|
||||
There is a problem with the ":append" and ":insert" commands: >
|
||||
:1append
|
||||
\asdf
|
||||
@@ -792,6 +795,10 @@ won't be very helpful.
|
||||
|
||||
There is a separate command-line history for debug mode.
|
||||
|
||||
NOTE: In Vim9 script, if a command is written at the script level and
|
||||
continues on the next line, not using the old way with a backslash for line
|
||||
continuation, only the first line is printed before the debugging prompt.
|
||||
|
||||
The line number for a function line is relative to the start of the function.
|
||||
If you have trouble figuring out where you are, edit the file that defines
|
||||
the function in another Vim, search for the start of the function and do
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*sign.txt* For Vim version 8.2. Last change: 2021 Mar 07
|
||||
*sign.txt* For Vim version 8.2. Last change: 2021 Dec 05
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Gordon Prieur
|
||||
@@ -53,6 +53,8 @@ The color of the column is set with the SignColumn highlight group
|
||||
|
||||
:highlight SignColumn guibg=darkgrey
|
||||
<
|
||||
If 'cursorline' is enabled, then the CursorLineSign highlight group is used
|
||||
|hl-CursorLineSign|.
|
||||
*sign-identifier*
|
||||
Each placed sign is identified by a number called the sign identifier. This
|
||||
identifier is used to jump to the sign or to remove the sign. The identifier
|
||||
@@ -138,6 +140,11 @@ See |sign_define()| for the equivalent Vim script function.
|
||||
Highlighting group used for the whole line the sign is placed
|
||||
in. Most useful is defining a background color.
|
||||
|
||||
numhl={group}
|
||||
Highlighting group used for the line number on the line where
|
||||
the sign is placed. Overrides |hl-LineNr|, |hl-LineNrAbove|,
|
||||
|hl-LineNrBelow|, and |hl-CursorLineNr|.
|
||||
|
||||
text={text} *E239*
|
||||
Define the text that is displayed when there is no icon or the
|
||||
GUI is not being used. Only printable characters are allowed
|
||||
@@ -146,6 +153,10 @@ See |sign_define()| for the equivalent Vim script function.
|
||||
texthl={group}
|
||||
Highlighting group used for the text item.
|
||||
|
||||
culhl={group}
|
||||
Highlighting group used for the text item when the cursor is
|
||||
on the same line as the sign and 'cursorline' is enabled.
|
||||
|
||||
Example: >
|
||||
:sign define MySign text=>> texthl=Search linehl=DiffText
|
||||
<
|
||||
@@ -390,9 +401,14 @@ sign_define({list})
|
||||
icon full path to the bitmap file for the sign.
|
||||
linehl highlight group used for the whole line the
|
||||
sign is placed in.
|
||||
numhl highlight group used for the line number where
|
||||
the sign is placed.
|
||||
text text that is displayed when there is no icon
|
||||
or the GUI is not being used.
|
||||
texthl highlight group used for the text item
|
||||
culhl highlight group used for the text item when
|
||||
the cursor is on the same line as the sign and
|
||||
'cursorline' is enabled.
|
||||
|
||||
If the sign named {name} already exists, then the attributes
|
||||
of the sign are updated.
|
||||
@@ -432,11 +448,18 @@ sign_getdefined([{name}]) *sign_getdefined()*
|
||||
following entries:
|
||||
icon full path to the bitmap file of the sign
|
||||
linehl highlight group used for the whole line the
|
||||
sign is placed in.
|
||||
sign is placed in; not present if not set
|
||||
name name of the sign
|
||||
numhl highlight group used for the line number where
|
||||
the sign is placed; not present if not set
|
||||
text text that is displayed when there is no icon
|
||||
or the GUI is not being used.
|
||||
texthl highlight group used for the text item
|
||||
texthl highlight group used for the text item; not
|
||||
present if not set
|
||||
culhl highlight group used for the text item when
|
||||
the cursor is on the same line as the sign and
|
||||
'cursorline' is enabled; not present if not
|
||||
set
|
||||
|
||||
Returns an empty List if there are no signs and when {name} is
|
||||
not found.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*syntax.txt* For Vim version 8.2. Last change: 2021 Aug 16
|
||||
*syntax.txt* For Vim version 8.2. Last change: 2021 Nov 20
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -1081,33 +1081,47 @@ This works immediately.
|
||||
|
||||
CLOJURE *ft-clojure-syntax*
|
||||
|
||||
The default syntax groups can be augmented through the
|
||||
*g:clojure_syntax_keywords* and *b:clojure_syntax_keywords* variables. The
|
||||
value should be a |Dictionary| of syntax group names to a |List| of custom
|
||||
identifiers:
|
||||
*g:clojure_syntax_keywords*
|
||||
|
||||
Syntax highlighting of public vars in "clojure.core" is provided by default,
|
||||
but additional symbols can be highlighted by adding them to the
|
||||
|g:clojure_syntax_keywords| variable. The value should be a |Dictionary| of
|
||||
syntax group names, each containing a |List| of identifiers.
|
||||
>
|
||||
let g:clojure_syntax_keywords = {
|
||||
\ 'clojureMacro': ["defproject", "defcustom"],
|
||||
\ 'clojureFunc': ["string/join", "string/replace"]
|
||||
\ 'clojureMacro': ["defproject", "defcustom"],
|
||||
\ 'clojureFunc': ["string/join", "string/replace"]
|
||||
\ }
|
||||
<
|
||||
Refer to the Clojure syntax script for valid syntax group names.
|
||||
|
||||
If the |buffer-variable| *b:clojure_syntax_without_core_keywords* is set, only
|
||||
language constants and special forms are matched.
|
||||
There is also *b:clojure_syntax_keywords* which is a buffer-local variant of
|
||||
this variable intended for use by plugin authors to highlight symbols
|
||||
dynamically.
|
||||
|
||||
Setting *g:clojure_fold* enables folding Clojure code via the syntax engine.
|
||||
Any list, vector, or map that extends over more than one line can be folded
|
||||
using the standard Vim |fold-commands|.
|
||||
By setting the *b:clojure_syntax_without_core_keywords* variable, vars from
|
||||
"clojure.core" will not be highlighted by default. This is useful for
|
||||
namespaces that have set `(:refer-clojure :only [])`
|
||||
|
||||
Please note that this option does not work with scripts that redefine the
|
||||
bracket syntax regions, such as rainbow-parentheses plugins.
|
||||
|
||||
This option is off by default.
|
||||
*g:clojure_fold*
|
||||
|
||||
Setting |g:clojure_fold| to `1` will enable the folding of Clojure code. Any
|
||||
list, vector or map that extends over more than one line can be folded using
|
||||
the standard Vim |fold-commands|.
|
||||
|
||||
|
||||
*g:clojure_discard_macro*
|
||||
|
||||
Set this variable to `1` to enable basic highlighting of Clojure's "discard
|
||||
reader macro".
|
||||
>
|
||||
" Default
|
||||
let g:clojure_fold = 0
|
||||
#_(defn foo [x]
|
||||
(println x))
|
||||
<
|
||||
Note that this option will not correctly highlight stacked discard macros
|
||||
(e.g. `#_#_`).
|
||||
|
||||
|
||||
COBOL *cobol.vim* *ft-cobol-syntax*
|
||||
|
||||
@@ -1519,6 +1533,14 @@ gvim display. Here, statements are colored LightYellow instead of Yellow, and
|
||||
conditionals are LightBlue for better distinction.
|
||||
|
||||
|
||||
FORTH *forth.vim* *ft-forth-syntax*
|
||||
|
||||
Files matching "*.fs" could be F# or Forth. If the automatic detection
|
||||
doesn't work for you, or you don't edit F# at all, use this in your
|
||||
startup vimrc: >
|
||||
:let filetype_fs = "forth"
|
||||
|
||||
|
||||
FORTRAN *fortran.vim* *ft-fortran-syntax*
|
||||
|
||||
Default highlighting and dialect ~
|
||||
@@ -1673,16 +1695,6 @@ as Fvwm2 configuration files, add the following: >
|
||||
:au! BufNewFile,BufRead /etc/X11/fvwm2/* let b:fvwm_version = 2 |
|
||||
\ set filetype=fvwm
|
||||
|
||||
If you'd like Vim to highlight all valid color names, tell it where to
|
||||
find the color database (rgb.txt) on your system. Do this by setting
|
||||
"rgb_file" to its location. Assuming your color database is located
|
||||
in /usr/X11/lib/X11/, you should add the line >
|
||||
|
||||
:let rgb_file = "/usr/X11/lib/X11/rgb.txt"
|
||||
|
||||
to your .vimrc file.
|
||||
|
||||
|
||||
GSP *gsp.vim* *ft-gsp-syntax*
|
||||
|
||||
The default coloring style for GSP pages is defined by |html.vim|, and
|
||||
@@ -3184,6 +3196,14 @@ buffer by buffer basis.
|
||||
For more detailed instructions see |ft_sql.txt|.
|
||||
|
||||
|
||||
SQUIRREL *squirrel.vim* *ft-squirrel-syntax*
|
||||
|
||||
Squirrel is a high level imperative, object-oriented programming language,
|
||||
designed to be a light-weight scripting language that fits in the size, memory
|
||||
bandwidth, and real-time requirements of applications like video games. Files
|
||||
with the following extensions are recognized as squirrel files: .nut.
|
||||
|
||||
|
||||
TCSH *tcsh.vim* *ft-tcsh-syntax*
|
||||
|
||||
This covers the shell named "tcsh". It is a superset of csh. See |csh.vim|
|
||||
@@ -4486,7 +4506,7 @@ it marks the "\(\I\i*\)" sub-expression as external; in the end pattern, it
|
||||
changes the \z1 back-reference into an external reference referring to the
|
||||
first external sub-expression in the start pattern. External references can
|
||||
also be used in skip patterns: >
|
||||
:syn region foo start="start \(\I\i*\)" skip="not end \z1" end="end \z1"
|
||||
:syn region foo start="start \z(\I\i*\)" skip="not end \z1" end="end \z1"
|
||||
|
||||
Note that normal and external sub-expressions are completely orthogonal and
|
||||
indexed separately; for instance, if the pattern "\z(..\)\(..\)" is applied
|
||||
@@ -4830,16 +4850,28 @@ in their own color.
|
||||
Doesn't work recursively, thus you can't use
|
||||
":colorscheme" in a color scheme script.
|
||||
|
||||
To customize a color scheme use another name, e.g.
|
||||
You have two options for customizing a color scheme.
|
||||
For changing the appearance of specific colors, you
|
||||
can redefine a color name before loading the scheme.
|
||||
The desert scheme uses the khaki color for the cursor.
|
||||
To use a darker variation of the same color: >
|
||||
|
||||
let v:colornames['khaki'] = '#bdb76b'
|
||||
colorscheme desert
|
||||
<
|
||||
For further customization, such as changing
|
||||
|:highlight-link| associations, use another name, e.g.
|
||||
"~/.vim/colors/mine.vim", and use `:runtime` to load
|
||||
the original color scheme: >
|
||||
runtime colors/evening.vim
|
||||
hi Statement ctermfg=Blue guifg=Blue
|
||||
|
||||
< Before the color scheme will be loaded the
|
||||
|ColorSchemePre| autocommand event is triggered.
|
||||
After the color scheme has been loaded the
|
||||
|ColorScheme| autocommand event is triggered.
|
||||
< Before the color scheme will be loaded all default
|
||||
color list scripts (`colors/lists/default.vim`) will
|
||||
be executed and then the |ColorSchemePre| autocommand
|
||||
event is triggered. After the color scheme has been
|
||||
loaded the |ColorScheme| autocommand event is
|
||||
triggered.
|
||||
For info about writing a color scheme file: >
|
||||
:edit $VIMRUNTIME/colors/README.txt
|
||||
|
||||
@@ -4849,6 +4881,7 @@ in their own color.
|
||||
:hi[ghlight] {group-name}
|
||||
List one highlight group.
|
||||
|
||||
*highlight-clear*
|
||||
:hi[ghlight] clear Reset all highlighting to the defaults. Removes all
|
||||
highlighting for groups added by the user!
|
||||
Uses the current value of 'background' to decide which
|
||||
@@ -4862,7 +4895,9 @@ in their own color.
|
||||
|
||||
:hi[ghlight] [default] {group-name} {key}={arg} ..
|
||||
Add a highlight group, or change the highlighting for
|
||||
an existing group.
|
||||
an existing group. If a given color name is not
|
||||
recognized, each `colors/lists/default.vim` found on
|
||||
|'runtimepath'| will be loaded.
|
||||
See |highlight-args| for the {key}={arg} arguments.
|
||||
See |:highlight-default| for the optional [default]
|
||||
argument.
|
||||
@@ -5143,8 +5178,35 @@ guisp={color-name} *highlight-guisp*
|
||||
"gg" is the Green value
|
||||
"bb" is the Blue value
|
||||
All values are hexadecimal, range from "00" to "ff". Examples: >
|
||||
:highlight Comment guifg=#11f0c3 guibg=#ff00ff
|
||||
:highlight Comment guifg=#11f0c3 guibg=#ff00ff
|
||||
<
|
||||
If you are authoring a color scheme and use the same hexademical value
|
||||
repeatedly, you can define a name for it in |v:colornames|. For
|
||||
example: >
|
||||
|
||||
# provide a default value for this color but allow the user to
|
||||
# override it.
|
||||
:call extend(v:colornames, {'alt_turquoise': '#11f0c3'}, 'keep')
|
||||
:highlight Comment guifg=alt_turquoise guibg=magenta
|
||||
<
|
||||
If you are using a color scheme that relies on named colors and you
|
||||
would like to adjust the precise appearance of those colors, you can
|
||||
do so by overriding the values in |v:colornames| prior to loading the
|
||||
scheme: >
|
||||
|
||||
let v:colornames['alt_turquoise'] = '#22f0d3'
|
||||
colorscheme alt
|
||||
<
|
||||
If you want to develop a color list that can be relied on by others,
|
||||
it is best to prefix your color names. By convention these color lists
|
||||
are placed in the colors/lists directory. You can see an example in
|
||||
'$VIMRUNTIME/colors/lists/csscolors.vim'. This list would be sourced
|
||||
by a color scheme using: >
|
||||
|
||||
:runtime colors/lists/csscolors.vim
|
||||
:highlight Comment guifg=css_turquoise
|
||||
<
|
||||
|
||||
*highlight-groups* *highlight-default*
|
||||
These are the default highlighting groups. These groups are used by the
|
||||
'highlight' option default. Note that the highlighting depends on the value
|
||||
@@ -5205,6 +5267,10 @@ LineNrBelow Line number for when the 'relativenumber'
|
||||
*hl-CursorLineNr*
|
||||
CursorLineNr Like LineNr when 'cursorline' is set and 'cursorlineopt'
|
||||
contains "number" or is "both", for the cursor line.
|
||||
*hl-CursorLineSign*
|
||||
CursorLineSign Like SignColumn when 'cursorline' is set for the cursor line.
|
||||
*hl-CursorLineFold*
|
||||
CursorLineFold Like FoldColumn when 'cursorline' is set for the cursor line.
|
||||
*hl-MatchParen*
|
||||
MatchParen The character under the cursor or just before it, if it
|
||||
is a paired bracket, and its match. |pi_paren.txt|
|
||||
@@ -5431,7 +5497,7 @@ For Unix you can use the file ~/.vim/after/syntax/syncolor.vim. Example: >
|
||||
else
|
||||
highlight comment ctermfg=green guifg=green
|
||||
endif
|
||||
|
||||
<
|
||||
*E679*
|
||||
Do make sure this syncolor.vim script does not use a "syntax on", set the
|
||||
'background' option or uses a "colorscheme" command, because it results in an
|
||||
@@ -5444,11 +5510,11 @@ depends on the color scheme file. See |:colorscheme|.
|
||||
*syntax_cmd*
|
||||
The "syntax_cmd" variable is set to one of these values when the
|
||||
syntax/syncolor.vim files are loaded:
|
||||
"on" ":syntax on" command. Highlight colors are overruled but
|
||||
"on" `:syntax on` command. Highlight colors are overruled but
|
||||
links are kept
|
||||
"enable" ":syntax enable" command. Only define colors for groups that
|
||||
don't have highlighting yet. Use ":syntax default".
|
||||
"reset" ":syntax reset" command or loading a color scheme. Define all
|
||||
"enable" `:syntax enable` command. Only define colors for groups that
|
||||
don't have highlighting yet. Use `:highlight default` .
|
||||
"reset" `:syntax reset` command or loading a color scheme. Define all
|
||||
the colors.
|
||||
"skip" Don't define colors. Used to skip the default settings when a
|
||||
syncolor.vim file earlier in 'runtimepath' has already set
|
||||
|
||||
1064
runtime/doc/tags
1064
runtime/doc/tags
File diff suppressed because it is too large
Load Diff
@@ -1,4 +1,4 @@
|
||||
*term.txt* For Vim version 8.2. Last change: 2021 Aug 29
|
||||
*term.txt* For Vim version 8.2. Last change: 2021 Dec 21
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -150,8 +150,10 @@ terminal that tmux is running in): >
|
||||
" Enable focus event tracking, see :help xterm-focus-event
|
||||
let &t_fe = "\<Esc>[?1004h"
|
||||
let &t_fd = "\<Esc>[?1004l"
|
||||
execute "set <FocusGained>=\<Esc>[I"
|
||||
execute "set <FocusLost>=\<Esc>[O"
|
||||
|
||||
" Enable modified arrow keys, see :help xterm-modifier-keys
|
||||
" Enable modified arrow keys, see :help arrow_modifiers
|
||||
execute "silent! set <xUp>=\<Esc>[@;*A"
|
||||
execute "silent! set <xDown>=\<Esc>[@;*B"
|
||||
execute "silent! set <xRight>=\<Esc>[@;*C"
|
||||
@@ -252,7 +254,19 @@ another code. That is to avoid that the codes obtained from xterm directly
|
||||
Another special value is a termcap entry ending in "@;*X". This is for cursor
|
||||
keys, which either use "CSI X" or "CSI 1 ; modifier X". Thus the "@"
|
||||
stands for either "1" if a modifier follows, or nothing.
|
||||
*xterm-scroll-region*
|
||||
*arrow_modifiers*
|
||||
Several terminal emulators (alacritty, gnome, konsole, etc.) send special
|
||||
codes for keys with modifiers, but these do not have an entry in the
|
||||
termcap/terminfo database. You can make them work by adding a few lines in
|
||||
your vimrc. For example, to make the Control modifier work with arrow keys
|
||||
for the gnome terminal: >
|
||||
if &term =~ 'gnome'
|
||||
execute "set <xUp>=\<Esc>[@;*A"
|
||||
execute "set <xDown>=\<Esc>[@;*B"
|
||||
execute "set <xRight>=\<Esc>[@;*C"
|
||||
execute "set <xLeft>=\<Esc>[@;*D"
|
||||
endif
|
||||
< *xterm-scroll-region*
|
||||
The default termcap entry for xterm on Sun and other platforms does not
|
||||
contain the entry for scroll regions. Add ":cs=\E[%i%d;%dr:" to the xterm
|
||||
entry in /etc/termcap and everything should work.
|
||||
@@ -542,8 +556,15 @@ request the key codes directly from the xterm. The responses are used to
|
||||
adjust the various t_ codes. This avoids the problem that the xterm can
|
||||
produce different codes, depending on the mode it is in (8-bit, VT102,
|
||||
VT220, etc.). The result is that codes like <xF1> are no longer needed.
|
||||
Note: This is only done on startup. If the xterm options are changed after
|
||||
Vim has started, the escape sequences may not be recognized anymore.
|
||||
|
||||
One of the codes that can change is 't_Co', the number of colors. This will
|
||||
trigger a redraw. If this is a problem, reset the 'xtermcodes' option as
|
||||
early as possible: >
|
||||
set noxtermcodes
|
||||
|
||||
Note: Requesting the key codes is only done on startup. If the xterm options
|
||||
are changed after Vim has started, the escape sequences may not be recognized
|
||||
anymore.
|
||||
|
||||
*xterm-true-color*
|
||||
Vim supports using true colors in the terminal (taken from |highlight-guifg|
|
||||
@@ -594,6 +615,8 @@ If your terminal does support this but Vim does not recognize the terminal,
|
||||
you may have to set the options yourself: >
|
||||
let &t_fe = "\<Esc>[?1004h"
|
||||
let &t_fd = "\<Esc>[?1004l"
|
||||
execute "set <FocusGained>=\<Esc>[I"
|
||||
execute "set <FocusLost>=\<Esc>[O"
|
||||
If this causes garbage to show when Vim starts up then it doesn't work.
|
||||
|
||||
*termcap-colors*
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*terminal.txt* For Vim version 8.2. Last change: 2021 Aug 15
|
||||
*terminal.txt* For Vim version 8.2. Last change: 2021 Dec 21
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -240,7 +240,7 @@ Command syntax ~
|
||||
++shell Instead of executing {command}
|
||||
directly, use a shell, like with
|
||||
`:!command` *E279*
|
||||
{only works on Unix currently}
|
||||
{only works on Unix and MS-Windows}
|
||||
++kill={how} When trying to close the terminal
|
||||
window kill the job with {how}. See
|
||||
|term_setkill()| for the values.
|
||||
@@ -871,7 +871,8 @@ term_start({cmd} [, {options}]) *term_start()*
|
||||
"term_name" name to use for the buffer name, instead
|
||||
of the command name.
|
||||
"term_rows" vertical size to use for the terminal,
|
||||
instead of using 'termwinsize'
|
||||
instead of using 'termwinsize'; valid
|
||||
range is from zero to 1000
|
||||
"term_cols" horizontal size to use for the terminal,
|
||||
instead of using 'termwinsize'
|
||||
"vertical" split the window vertically; note that
|
||||
@@ -1427,6 +1428,8 @@ GDB command *termdebug-customizing*
|
||||
To change the name of the gdb command, set the "g:termdebugger" variable before
|
||||
invoking `:Termdebug`: >
|
||||
let g:termdebugger = "mygdb"
|
||||
If the command needs an argument use a List: >
|
||||
let g:termdebugger = ['rr', 'replay', '--']
|
||||
< *gdb-version*
|
||||
Only debuggers fully compatible with gdb will work. Vim uses the GDB/MI
|
||||
interface. The "new-ui" command requires gdb version 7.12 or later. if you
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*testing.txt* For Vim version 8.2. Last change: 2021 Aug 15
|
||||
*testing.txt* For Vim version 8.2. Last change: 2021 Dec 11
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -65,7 +65,8 @@ test_garbagecollect_now() *test_garbagecollect_now()*
|
||||
Like garbagecollect(), but executed right away. This must
|
||||
only be called directly to avoid any structure to exist
|
||||
internally, and |v:testing| must have been set before calling
|
||||
any function.
|
||||
any function. This will not work when called from a :def
|
||||
function, because variables on the stack will be freed.
|
||||
|
||||
|
||||
test_garbagecollect_soon() *test_garbagecollect_soon()*
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*textprop.txt* For Vim version 8.2. Last change: 2021 Aug 16
|
||||
*textprop.txt* For Vim version 8.2. Last change: 2021 Nov 23
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -230,13 +230,25 @@ prop_find({props} [, {direction}])
|
||||
|
||||
|
||||
prop_list({lnum} [, {props}]) *prop_list()*
|
||||
Return a List with all text properties in line {lnum}.
|
||||
Returns a List with all the text properties in line {lnum}.
|
||||
|
||||
When {props} contains a "bufnr" item, use this buffer instead
|
||||
of the current buffer.
|
||||
The following optional items are supported in {props}:
|
||||
bufnr use this buffer instead of the current buffer
|
||||
end_lnum return text properties in all the lines
|
||||
between {lnum} and {end_lnum} (inclusive).
|
||||
A negative value is used as an offset from the
|
||||
last buffer line; -1 refers to the last buffer
|
||||
line.
|
||||
types List of property type names. Return only text
|
||||
properties that match one of the type names.
|
||||
ids List of property identifiers. Return only text
|
||||
properties with one of these identifiers.
|
||||
|
||||
The properties are ordered by starting column and priority.
|
||||
Each property is a Dict with these entries:
|
||||
lnum starting line number. Present only when
|
||||
returning text properties between {lnum} and
|
||||
{end_lnum}.
|
||||
col starting column
|
||||
length length in bytes, one more if line break is
|
||||
included
|
||||
@@ -253,6 +265,30 @@ prop_list({lnum} [, {props}]) *prop_list()*
|
||||
When "end" is zero the property continues in the next line.
|
||||
The line break after this line is included.
|
||||
|
||||
Returns an empty list on error.
|
||||
|
||||
Examples:
|
||||
" get text properties placed in line 5
|
||||
echo prop_list(5)
|
||||
" get text properties placed in line 20 in buffer 4
|
||||
echo prop_list(20, {'bufnr': 4})
|
||||
" get all the text properties between line 1 and 20
|
||||
echo prop_list(1, {'end_lnum': 20})
|
||||
" get all the text properties of type 'myprop'
|
||||
echo prop_list(1, {'types': ['myprop'],
|
||||
\ 'end_lnum': -1})
|
||||
" get all the text properties of type 'prop1' or 'prop2'
|
||||
echo prop_list(1, {'types': ['prop1', 'prop2'],
|
||||
\ 'end_lnum': -1})
|
||||
" get all the text properties with ID 8
|
||||
echo prop_list(1, {'ids': [8], 'end_lnum': line('$')})
|
||||
" get all the text properties with ID 10 and 20
|
||||
echo prop_list(1, {'ids': [10, 20], 'end_lnum': -1})
|
||||
" get text properties with type 'myprop' and ID 100
|
||||
" in buffer 4.
|
||||
echo prop_list(1, {'bufnr': 4, 'types': ['myprop'],
|
||||
\ 'ids': [100], 'end_lnum': -1})
|
||||
|
||||
Can also be used as a |method|: >
|
||||
GetLnum()->prop_list()
|
||||
<
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*tips.txt* For Vim version 8.2. Last change: 2020 Dec 29
|
||||
*tips.txt* For Vim version 8.2. Last change: 2021 Nov 06
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -549,6 +549,7 @@ the current window, try this custom `:HelpCurwin` command:
|
||||
endif
|
||||
if !getcompletion(a:subject, 'help')->empty()
|
||||
execute mods .. ' edit ' .. &helpfile
|
||||
set buftype=help
|
||||
endif
|
||||
return 'help ' .. a:subject
|
||||
endfunction
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*todo.txt* For Vim version 8.2. Last change: 2021 Oct 15
|
||||
*todo.txt* For Vim version 8.2. Last change: 2021 Dec 30
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -38,40 +38,14 @@ browser use: https://github.com/vim/vim/issues/1234
|
||||
*known-bugs*
|
||||
-------------------- Known bugs and current work -----------------------
|
||||
|
||||
Remove s:flaky_tests from runtest.vim, set g:test_is_flaky in each test.
|
||||
|
||||
Vim9 - Make everything work:
|
||||
- "filter #pat# ls" should work, #pat# is not a comment
|
||||
vim9script
|
||||
edit foobar
|
||||
filter #foobar# ls
|
||||
- Check TODO items in vim9compile.c and vim9execute.c
|
||||
- use CheckLegacyAndVim9Success(lines) in many more places
|
||||
- For builtin functions using tv_get_string*() use check_for_string() to be
|
||||
more strict about the argument type (not a bool).
|
||||
done: balloon_()
|
||||
- Check many more builtin function arguments at compile time.
|
||||
map() could check that the return type of the function argument matches
|
||||
the type of the list or dict member. (#8092)
|
||||
Same for other functions, such as searchpair().
|
||||
- Test try/catch and throw better, also nested.
|
||||
Test that return inside try/finally jumps to finally and then returns.
|
||||
- Test that a function defined inside a :def function is local to that
|
||||
function, g: functions can be defined and script-local functions cannot be
|
||||
defined.
|
||||
- Unexpected error message when using "var x: any | x.key = 9", because "x" is
|
||||
given the type number. Can we use VAR_ANY?
|
||||
- Check performance with callgrind and kcachegrind.
|
||||
|
||||
Once Vim9 is stable:
|
||||
- Add the "vim9script" feature, can use has('vim9script')
|
||||
- Change the help to prefer Vim9 syntax where appropriate
|
||||
Remove TODO in vim9.txt
|
||||
- Add all the error numbers in a good place in documentation.
|
||||
- In the generic eval docs, point out the Vim9 syntax where it differs.
|
||||
- Use Vim9 for runtime files.
|
||||
PR #7497 for autoload/ccomplete.vim
|
||||
|
||||
Further Vim9 improvements, possibly after launch:
|
||||
- Check performance with callgrind and kcachegrind.
|
||||
- better implementation for partial and tests for that.
|
||||
- Compile options that are an expression, e.g. "expr:" in 'spellsuggest',
|
||||
'foldexpr', 'foldtext', 'printexpr', 'diffexpr', 'patchexpr', 'charconvert',
|
||||
@@ -81,10 +55,9 @@ Further Vim9 improvements, possibly after launch:
|
||||
evaluation.
|
||||
Use the location where the option was set for deciding whether it's to be
|
||||
evaluated in Vim9 script context.
|
||||
- Handle command that is only a range more efficient than calling ISN_EXEC
|
||||
- implement :type, "import type"
|
||||
- implement enum, "import enum".
|
||||
- implement class and interface: See |vim9-classes|
|
||||
- implement :enum, "import enum".
|
||||
- implement :class and :interface: See |vim9-classes|
|
||||
- For range: make table of first ASCII character with flag to quickly check if
|
||||
it can be a Vim9 command. E.g. "+" can, but "." can't.
|
||||
- Inline call to map() and filter(), better type checking.
|
||||
@@ -95,6 +68,9 @@ Further Vim9 improvements, possibly after launch:
|
||||
has(featureName), len(someString)
|
||||
- Implement as part of an expression: ++expr, --expr, expr++, expr--.
|
||||
|
||||
Update list of features to vote on:
|
||||
- multiple cursors
|
||||
- built-in LSP support
|
||||
|
||||
Popup windows:
|
||||
- Preview popup not properly updated when it overlaps with completion menu.
|
||||
@@ -137,8 +113,6 @@ Text properties:
|
||||
where property fits in.
|
||||
Or Should we let the textprop highlight overrule other (e.g. diff) highlight
|
||||
if the priority is above a certain value? (#7392)
|
||||
- Popup attached to text property stays visible when text is no longer
|
||||
visible. (#7736)
|
||||
- Popup attached to text property stays visible when text is deleted with
|
||||
"cc". (#7737) "C" works OK. "dd" also files in a buffer with a single
|
||||
line.
|
||||
@@ -200,8 +174,6 @@ Terminal emulator window:
|
||||
- GUI: When using ":set go+=!" a system() call causes the hit-enter prompt.
|
||||
(#3327)
|
||||
- Allow for specifying the directory, with ++cwd={dir}.
|
||||
- With a vertical split only one window is updated. (Linwei, 2018 Jun 2,
|
||||
#2977)
|
||||
- When pasting should call vterm_keyboard_start_paste(), e.g. when using
|
||||
K_MIDDLEMOUSE, calling insert_reg().
|
||||
- Users expect parsing the :term argument like a shell does, also support
|
||||
@@ -220,8 +192,6 @@ Terminal emulator window:
|
||||
- When 'encoding' is not utf-8, or the job is using another encoding, setup
|
||||
conversions.
|
||||
|
||||
Include patch #6290: recognize shell directory change.
|
||||
|
||||
When using 'cryptmethod' xchaha20 the undo file is not encrypted.
|
||||
Need to handle extra bytes.
|
||||
|
||||
@@ -231,6 +201,8 @@ Fails in line 64 of Ch_communicate, no exception is thrown.
|
||||
Patch for Template string: #4634
|
||||
Have another look at the implementation.
|
||||
|
||||
Add expanding <script> which works like <sfile> everywhere. #9189
|
||||
|
||||
Rename getdigraphlist -> digraph_getlist() etc.
|
||||
|
||||
Valgrind reports memory leaks in test_options.
|
||||
@@ -263,6 +235,10 @@ test_arglist func Test_all_not_allowed_from_cmdwin() hangs on MS-Windows.
|
||||
|
||||
Mapping with partial match not executed properly in GTK. (Ingo Karkat, #7082)
|
||||
|
||||
Information for a specific terminal (e.g. gnome, tmux, konsole, alacritty) is
|
||||
spread out. Make a section with copy/paste examples of script and pointers to
|
||||
more information.
|
||||
|
||||
Problem that a previous silent ":throw" causes a following try/catch not to
|
||||
work. (ZyX, 2013 Sep 28) With examples: (Malcolm Rowe, 2015 Dec 24)
|
||||
Also see #8487 for an example.
|
||||
@@ -273,12 +249,18 @@ Was originally written by Felipe Morales.
|
||||
Request to use "." for the cursor column in search pattern \%<.c and \%<.v.
|
||||
(#8179)
|
||||
|
||||
":filter set termcap" only filters terminal codes, not keys. (#9297)
|
||||
|
||||
Remove SPACE_IN_FILENAME ? It is only used for completion.
|
||||
|
||||
When 'term' starts with "foot" then default t_TI and t_TE to the values used
|
||||
for the builtin xterm termcap.
|
||||
|
||||
Adding "10" to 'spellsuggest' causes spell suggestions to become very slow.
|
||||
(#4087) Did patch 8.2.2379 help?
|
||||
Also, z= in German on a long word can take a very long time, but CTRL-C to
|
||||
interrupt does not work. Where to add ui_breakcheck()?
|
||||
|
||||
Remove SPACE_IN_FILENAME ? It is only used for completion.
|
||||
New English spell files also have very slow suggestions.
|
||||
|
||||
Searching for \%'> does not find anything when using line Visual selection.
|
||||
Probably because it's using MAXCOL. #8238
|
||||
@@ -413,8 +395,6 @@ Motif: Build on Ubuntu can't enter any text in dialog text fields.
|
||||
Running test_gui and test_gui_init with Motif sometimes kills the window
|
||||
manager. Problem with Motif?
|
||||
|
||||
Patch to add :argdedupe. (Nir Lichtman, #6235)
|
||||
|
||||
When editing a file with ":edit" the output of :swapname is relative, while
|
||||
editing it with "vim file" it is absolute. (#355)
|
||||
Which one should it be?
|
||||
@@ -655,14 +635,6 @@ http://vimawesome.com/?q=tag:color-scheme
|
||||
Bug: "vipgw" does not put cursor back where it belongs. (Jason Franklin, 2019
|
||||
Mar 5)
|
||||
|
||||
Many users don't like 'thesaurus' to match so many words. (#4667, #1611)
|
||||
- when the match with the first word is partial, don't add other words on that
|
||||
line.
|
||||
- support other file formats, such as comma separated. Indicate by a prefix
|
||||
to the file in the 'thesaurus' option.
|
||||
- 'threglookexp' option: only match with first word in thesaurus file.
|
||||
(Jakson A. Aquino, 2006 Jun 14)
|
||||
|
||||
Some composing characters actually add a cell width to the character they are
|
||||
on top off, making the whole thing two characters wide. (#4526)
|
||||
|
||||
@@ -852,9 +824,7 @@ window for the buffer.
|
||||
Win32 key codes are messy. Mike Williams tried to fix that, but now old
|
||||
mappings no longer work. Create a new terminal for the better solution?
|
||||
|
||||
Compiler warnings (geeknik, 2017 Oct 26):
|
||||
- signed integer overflow in do_sub() (#2249)
|
||||
- signed integer overflow in get_address() (#2248)
|
||||
Compiler warning (geeknik, 2017 Oct 26):
|
||||
- undefined left shift in get_string_tv() (#2250)
|
||||
|
||||
Add Native language protocol server (LSP) support. (Yegappan Lakshmanan, 2018
|
||||
@@ -1474,10 +1444,6 @@ When the CursorMovedI event triggers, and CTRL-X was typed, a script cannot
|
||||
restore the mode properly. (Andrew Stewart, 2016 Apr 20)
|
||||
Do not trigger the event?
|
||||
|
||||
Patch to fix display of listchars on the cursorline. (Nayuri Aohime, 2013)
|
||||
Update suggested by Yasuhiro Matsumoto, 2014 Nov 25:
|
||||
https://gist.github.com/presuku/d3d6b230b9b6dcfc0477
|
||||
|
||||
Patch to make the behavior of "w" more straightforward, but not Vi compatible.
|
||||
With a 'cpo' flag. (Christian Brabandt, 2016 Feb 8)
|
||||
|
||||
@@ -3905,7 +3871,7 @@ User Friendlier:
|
||||
$HOME/_vimrc, etc.) and add "edit vimrc" to the File menu.
|
||||
- Add a way to save local settings and mappings into a new plugin file.
|
||||
":mkplugin <file>"?
|
||||
- Add mappings local to a window: ":map <window> ..."?
|
||||
- Add mappings local to a window: ":map <window> ..." #9339
|
||||
9 Add buffer-local menu. Should offer a choice between removing the menu or
|
||||
disabling it. Be careful that tear-offs don't disappear (keep one empty
|
||||
item?).
|
||||
@@ -4163,6 +4129,9 @@ Printing:
|
||||
|
||||
|
||||
Syntax highlighting:
|
||||
Long term goal: faster, better, etc. Options:
|
||||
- use treesitter, NeoVim uses it
|
||||
- use TextMate, vscode uses it. #9087
|
||||
8 Make ":syn off" use 'runtimepath' instead of $VIMRUNTIME. (Gary Johnson)
|
||||
Should do the same for ":syn on" and ":syn manual".
|
||||
8 Support "containedin" argument for ":syn include", so that the defined
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*usr_06.txt* For Vim version 8.2. Last change: 2019 Jun 01
|
||||
*usr_06.txt* For Vim version 8.2. Last change: 2021 Nov 07
|
||||
|
||||
VIM USER MANUAL - by Bram Moolenaar
|
||||
|
||||
@@ -184,7 +184,30 @@ this command: >
|
||||
:runtime syntax/colortest.vim
|
||||
|
||||
You will see text in various color combinations. You can check which ones are
|
||||
readable and look nice.
|
||||
readable and look nice. These aren't the only colors available to you though.
|
||||
You can specify #rrggbb hex colors and you can define new names for hex
|
||||
colors in |v:colornames| like so: >
|
||||
|
||||
let v:colornames['mine_red'] = '#aa0000'
|
||||
<
|
||||
If you are authoring a color scheme for others to use, it is important
|
||||
to define these colors only when they do not exist: >
|
||||
|
||||
call extend(v:colornames, {'mine_red': '#aa0000'}, 'keep')
|
||||
|
||||
This allows users of the color scheme to override the precise definition of
|
||||
that color prior to loading your color scheme. For example, in a |.vimrc|
|
||||
file:
|
||||
|
||||
runtime colors/lists/css_colors.vim
|
||||
let v:colornames['your_red'] = v:colornames['css_red']
|
||||
colorscheme yourscheme
|
||||
|
||||
As a color scheme author, you should be able to rely on some color names for
|
||||
GUI colors. These are defined in `colors/lists/default.vim`. All such files
|
||||
found on the |'runtimepath'| are loaded each time the colorscheme command is
|
||||
run. A canonical list is provided by the vim distribution, which should
|
||||
include all X11 colors (previously defined in rgb.txt).
|
||||
|
||||
==============================================================================
|
||||
*06.4* With colors or without colors
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*usr_20.txt* For Vim version 8.2. Last change: 2006 Apr 24
|
||||
*usr_20.txt* For Vim version 8.2. Last change: 2021 Nov 18
|
||||
|
||||
VIM USER MANUAL - by Bram Moolenaar
|
||||
|
||||
@@ -289,11 +289,11 @@ In chapter 3 we briefly mentioned the history. The basics are that you can
|
||||
use the <Up> key to recall an older command line. <Down> then takes you back
|
||||
to newer commands.
|
||||
|
||||
There are actually four histories. The ones we will mention here are for ":"
|
||||
There are actually five histories. The ones we will mention here are for ":"
|
||||
commands and for "/" and "?" search commands. The "/" and "?" commands share
|
||||
the same history, because they are both search commands. The two other
|
||||
histories are for expressions and input lines for the input() function.
|
||||
|cmdline-history|
|
||||
the same history, because they are both search commands. The three other
|
||||
histories are for expressions, debug mode commands and input lines for the
|
||||
input() function. |cmdline-history|
|
||||
|
||||
Suppose you have done a ":set" command, typed ten more colon commands and then
|
||||
want to repeat that ":set" command again. You could press ":" and then ten
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,4 +1,4 @@
|
||||
*various.txt* For Vim version 8.2. Last change: 2021 Sep 06
|
||||
*various.txt* For Vim version 8.2. Last change: 2021 Dec 20
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -369,7 +369,7 @@ N *+digraphs* |digraphs| *E196*
|
||||
*+dnd* Support for DnD into the "~ register |quote_~|.
|
||||
B *+emacs_tags* |emacs-tags| files
|
||||
N *+eval* expression evaluation |eval.txt|
|
||||
N *+ex_extra* always on now, used to be for Vim's extra Ex commands
|
||||
T *+ex_extra* always on now, used to be for Vim's extra Ex commands
|
||||
N *+extra_search* |'hlsearch'| and |'incsearch'| options.
|
||||
- *+farsi* Removed: |farsi| language
|
||||
N *+file_in_path* |gf|, |CTRL-W_f| and |<cfile>|
|
||||
@@ -391,7 +391,7 @@ m *+hangul_input* Hangul input support |hangul|
|
||||
T *+insert_expand* |insert_expand| Insert mode completion
|
||||
m *+ipv6* Support for IPv6 networking |channel|
|
||||
m *+job* starting and stopping jobs |job|
|
||||
S *+jumplist* |jumplist|
|
||||
T *+jumplist* |jumplist|; Always enabled since 8.2.3795
|
||||
B *+keymap* |'keymap'|
|
||||
N *+lambda* |lambda| and |closure|
|
||||
B *+langmap* |'langmap'|
|
||||
@@ -423,7 +423,7 @@ N *+multi_lang* non-English language support |multi-lang|
|
||||
m *+mzscheme* Mzscheme interface |mzscheme|
|
||||
m *+mzscheme/dyn* Mzscheme interface |mzscheme-dynamic| |/dyn|
|
||||
m *+netbeans_intg* |netbeans|
|
||||
*+num64* 64-bit Number support |Number|
|
||||
T *+num64* 64-bit Number support |Number|
|
||||
Always enabled since 8.2.0271, use v:numbersize to
|
||||
check the actual size of a Number.
|
||||
m *+ole* Win32 GUI only: |ole-interface|
|
||||
@@ -471,15 +471,16 @@ N *+textobjects* |text-objects| selection
|
||||
N *+textprop* |text-properties|
|
||||
*+tgetent* non-Unix only: able to use external termcap
|
||||
N *+timers* the |timer_start()| function
|
||||
N *+title* Setting the window 'title' and 'icon'
|
||||
T *+title* Setting the window 'title' and 'icon'; Always enabled
|
||||
N *+toolbar* |gui-toolbar|
|
||||
T *+user_commands* User-defined commands. |user-commands|
|
||||
Always enabled since 8.1.1210.
|
||||
B *+vartabs* Variable-width tabstops. |'vartabstop'|
|
||||
N *+viminfo* |'viminfo'|
|
||||
*+vertsplit* Vertically split windows |:vsplit|; Always enabled
|
||||
T *+vertsplit* Vertically split windows |:vsplit|; Always enabled
|
||||
since 8.0.1118.
|
||||
N *+virtualedit* |'virtualedit'| Always enabled since 8.1.826.
|
||||
T *+vim9script* |Vim9| script
|
||||
N *+viminfo* |'viminfo'|
|
||||
T *+virtualedit* |'virtualedit'| Always enabled since 8.1.826.
|
||||
T *+visual* Visual mode |Visual-mode| Always enabled since 7.4.200.
|
||||
T *+visualextra* extra Visual mode commands |blockwise-operators|
|
||||
T *+vreplace* |gR| and |gr|
|
||||
@@ -549,14 +550,17 @@ N *+X11* Unix only: can restore window title |X11|
|
||||
name can be omitted.
|
||||
:redi[r] @">> Append messages to the unnamed register.
|
||||
|
||||
:redi[r] => {var} Redirect messages to a variable. If the variable
|
||||
doesn't exist, then it is created. If the variable
|
||||
exists, then it is initialized to an empty string.
|
||||
:redi[r] => {var} Redirect messages to a variable.
|
||||
In legacy script: If the variable doesn't exist, then
|
||||
it is created. If the variable exists, then it is
|
||||
initialized to an empty string. After the redirection
|
||||
starts, if the variable is removed or locked or the
|
||||
variable type is changed, then further command output
|
||||
messages will cause errors.
|
||||
In Vim9 script: the variable must have been declared
|
||||
as a string.
|
||||
The variable will remain empty until redirection ends.
|
||||
Only string variables can be used. After the
|
||||
redirection starts, if the variable is removed or
|
||||
locked or the variable type is changed, then further
|
||||
command output messages will cause errors.
|
||||
Only string variables can be used.
|
||||
To get the output of one command the |execute()|
|
||||
function can be used instead of redirection.
|
||||
|
||||
@@ -598,7 +602,7 @@ N *+X11* Unix only: can restore window title |X11|
|
||||
|:oldfiles| - filter by file name
|
||||
|:registers| - filter by register contents
|
||||
(does not work multi-line)
|
||||
|:set| - filter by variable name
|
||||
|:set| - filter by option name
|
||||
|
||||
Only normal messages are filtered, error messages are
|
||||
not.
|
||||
|
||||
@@ -1,17 +1,14 @@
|
||||
*vim9.txt* For Vim version 8.2. Last change: 2021 Sep 13
|
||||
*vim9.txt* For Vim version 8.2. Last change: 2021 Dec 27
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
|
||||
|
||||
THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE
|
||||
|
||||
Vim9 script commands and expressions. *Vim9* *vim9*
|
||||
|
||||
Most expression help is in |eval.txt|. This file is about the new syntax and
|
||||
features in Vim9 script.
|
||||
|
||||
THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE
|
||||
|
||||
|
||||
1. What is Vim9 script? |Vim9-script|
|
||||
@@ -27,8 +24,6 @@ THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE
|
||||
|
||||
1. What is Vim9 script? *Vim9-script*
|
||||
|
||||
THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE
|
||||
|
||||
Vim script has been growing over time, while preserving backwards
|
||||
compatibility. That means bad choices from the past often can't be changed
|
||||
and compatibility with Vi restricts possible solutions. Execution is quite
|
||||
@@ -76,8 +71,6 @@ rewrite old scripts, they keep working as before. You may want to use a few
|
||||
|
||||
2. Differences from legacy Vim script *vim9-differences*
|
||||
|
||||
THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE
|
||||
|
||||
Overview ~
|
||||
|
||||
Brief summary of the differences you will most often encounter when using Vim9
|
||||
@@ -88,7 +81,7 @@ script and `:def` functions; details are below:
|
||||
echo "hello "
|
||||
.. yourName
|
||||
.. ", how are you?"
|
||||
- White space is required in many places.
|
||||
- White space is required in many places to improve readability.
|
||||
- Assign values without `:let`, declare variables with `:var`: >
|
||||
var count = 0
|
||||
count += 3
|
||||
@@ -101,8 +94,8 @@ script and `:def` functions; details are below:
|
||||
def CallMe(count: number, message: string): bool
|
||||
- Call functions without `:call`: >
|
||||
writefile(['done'], 'file.txt')
|
||||
- You cannot use `:xit`, `:t`, `:k`, `:append`, `:change`, `:insert`, `:open`,
|
||||
and `:s` or `:d` with only flags.
|
||||
- You cannot use old Ex commands `:xit`, `:t`, `:k`, `:append`, `:change`,
|
||||
`:insert`, `:open`, and `:s` or `:d` with only flags.
|
||||
- You cannot use curly-braces names.
|
||||
- A range before a command must be prefixed with a colon: >
|
||||
:%s/this/that
|
||||
@@ -169,8 +162,8 @@ created yet. In this case you can call `execute()` to invoke it at runtime. >
|
||||
|
||||
`:def` has no options like `:function` does: "range", "abort", "dict" or
|
||||
"closure". A `:def` function always aborts on an error (unless `:silent!` was
|
||||
used for the command or inside a `:try` block), does not get a range passed
|
||||
cannot be a "dict" function, and can always be a closure.
|
||||
used for the command or the error was caught a `:try` block), does not get a
|
||||
range passed cannot be a "dict" function, and can always be a closure.
|
||||
*vim9-no-dict-function*
|
||||
Later classes will be added, which replaces the "dict function" mechanism.
|
||||
For now you will need to pass the dictionary explicitly: >
|
||||
@@ -234,9 +227,10 @@ the "name#" prefix is sufficient. >
|
||||
def scriptname#function() # autoload
|
||||
|
||||
When using `:function` or `:def` to specify a nested function inside a `:def`
|
||||
function, this nested function is local to the code block it is defined in.
|
||||
In a `:def` function it is not possible to define a script-local function. It
|
||||
is possible to define a global function by using the "g:" prefix.
|
||||
function and no namespace was given, this nested function is local to the code
|
||||
block it is defined in. In a `:def` function it is not possible to define a
|
||||
script-local function. It is possible to define a global function by using
|
||||
the "g:" prefix.
|
||||
|
||||
When referring to a function and no "s:" or "g:" prefix is used, Vim will
|
||||
search for the function:
|
||||
@@ -353,11 +347,13 @@ And with autocommands: >
|
||||
Although using a :def function probably works better.
|
||||
|
||||
Declaring a variable with a type but without an initializer will initialize to
|
||||
zero, false or empty.
|
||||
false (for bool), empty (for string, list, dict, etc.) or zero (for number,
|
||||
any, etc.). This matters especially when using the "any" type, the value will
|
||||
default to the number zero.
|
||||
|
||||
In Vim9 script `:let` cannot be used. An existing variable is assigned to
|
||||
without any command. The same for global, window, tab, buffer and Vim
|
||||
variables, because they are not really declared. They can also be deleted
|
||||
variables, because they are not really declared. Those can also be deleted
|
||||
with `:unlet`.
|
||||
|
||||
`:lockvar` does not work on local variables. Use `:const` and `:final`
|
||||
@@ -395,8 +391,8 @@ later. Example: >
|
||||
endif
|
||||
enddef
|
||||
|
||||
If you would do it like this you get an error at compile time that
|
||||
"PluginFunc" does not exist, even when "g:loaded_plugin" does not exist: >
|
||||
If you do it like this, you get an error at compile time that "PluginFunc"
|
||||
does not exist, even when "g:loaded_plugin" does not exist: >
|
||||
def CallPluginFunc()
|
||||
if exists('g:loaded_plugin')
|
||||
PluginFunc() # Error - function not found
|
||||
@@ -420,12 +416,11 @@ similar to how a function argument can be ignored: >
|
||||
To ignore any remaining items: >
|
||||
[a, b; _] = longList
|
||||
|
||||
< *E1092*
|
||||
Declaring more than one variable at a time, using the unpack notation, is
|
||||
currently not supported: >
|
||||
var [v1, v2] = GetValues() # Error!
|
||||
That is because the type needs to be inferred from the list item type, which
|
||||
isn't that easy.
|
||||
possible. Each variable can have a type or infer it from the value: >
|
||||
var [v1: number, v2] = GetValues()
|
||||
Use this only when there is a list with values, declaring one variable per
|
||||
line is much easier to read and change later.
|
||||
|
||||
|
||||
Constants ~
|
||||
@@ -509,7 +504,7 @@ The function must already have been defined. >
|
||||
|
||||
When using `function()` the resulting type is "func", a function with any
|
||||
number of arguments and any return type (including void). The function can be
|
||||
defined later.
|
||||
defined later if the argument is in quotes.
|
||||
|
||||
|
||||
Lambda using => instead of -> ~
|
||||
@@ -560,7 +555,6 @@ This can be useful for a timer, for example: >
|
||||
echom 'Handler called ' .. count
|
||||
}, {repeat: 3})
|
||||
|
||||
|
||||
The ending "}" must be at the start of a line. It can be followed by other
|
||||
characters, e.g.: >
|
||||
var d = mapnew(dict, (k, v): string => {
|
||||
@@ -568,6 +562,24 @@ characters, e.g.: >
|
||||
})
|
||||
No command can follow the "{", only a comment can be used there.
|
||||
|
||||
*command-block*
|
||||
The block can also be used for defining a user command. Inside the block Vim9
|
||||
syntax will be used.
|
||||
|
||||
If the statements include a dictionary, its closing bracket must not be
|
||||
written at the start of a line. Otherwise, it would be parsed as the end of
|
||||
the block. This does not work: >
|
||||
command NewCommand {
|
||||
g:mydict = {
|
||||
'key': 'value',
|
||||
} # ERROR: will be recognized as the end of the block
|
||||
}
|
||||
Put the '}' after the last item to avoid this: >
|
||||
command NewCommand {
|
||||
g:mydict = {
|
||||
'key': 'value' }
|
||||
}
|
||||
|
||||
Rationale: The "}" cannot be after a command because it would require parsing
|
||||
the commands to find it. For consistency with that no command can follow the
|
||||
"{". Unfortunately this means using "() => { command }" does not work, line
|
||||
@@ -585,7 +597,7 @@ Also when confused with the start of a command block: >
|
||||
|
||||
|
||||
Automatic line continuation ~
|
||||
|
||||
*vim9-line-continuation*
|
||||
In many cases it is obvious that an expression continues on the next line. In
|
||||
those cases there is no need to prefix the line with a backslash (see
|
||||
|line-continuation|). For example, when a list spans multiple lines: >
|
||||
@@ -763,7 +775,7 @@ No curly braces expansion ~
|
||||
|
||||
|
||||
Dictionary literals ~
|
||||
|
||||
*vim9-literal-dict*
|
||||
Traditionally Vim has supported dictionary literals with a {} syntax: >
|
||||
let dict = {'key': value}
|
||||
|
||||
@@ -821,6 +833,16 @@ error. Example: >
|
||||
|
||||
For loop ~
|
||||
|
||||
The loop variable must not be declared yet: >
|
||||
var i = 1
|
||||
for i in [1, 2, 3] # Error!
|
||||
|
||||
It is possible to use a global variable though: >
|
||||
g:i = 1
|
||||
for g:i in [1, 2, 3]
|
||||
echo g:i
|
||||
endfor
|
||||
|
||||
Legacy Vim script has some tricks to make a for loop over a list handle
|
||||
deleting items at the current or previous item. In Vim9 script it just uses
|
||||
the index, if items are deleted then items in the list will be skipped.
|
||||
@@ -843,7 +865,7 @@ first if needed.
|
||||
|
||||
|
||||
Conditions and expressions ~
|
||||
|
||||
*vim9-boolean*
|
||||
Conditions and expressions are mostly working like they do in other languages.
|
||||
Some values are different from legacy Vim script:
|
||||
value legacy Vim script Vim9 script ~
|
||||
@@ -895,8 +917,8 @@ always converted to string: >
|
||||
'hello ' .. 123 == 'hello 123'
|
||||
'hello ' .. v:true == 'hello true'
|
||||
|
||||
Simple types are string, float, special and bool. For other types |string()|
|
||||
can be used.
|
||||
Simple types are Number, Float, Special and Bool. For other types |string()|
|
||||
should be used.
|
||||
*false* *true* *null*
|
||||
In Vim9 script one can use "true" for v:true, "false" for v:false and "null"
|
||||
for v:null. When converting a boolean to a string "false" and "true" are
|
||||
@@ -1040,8 +1062,6 @@ Using ++var or --var in an expression is not supported yet.
|
||||
|
||||
3. New style functions *fast-functions*
|
||||
|
||||
THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE
|
||||
|
||||
*:def*
|
||||
:def[!] {name}([arguments])[: {return-type}]
|
||||
Define a new function by the name {name}. The body of
|
||||
@@ -1121,17 +1141,11 @@ function scope. Instead, use a lambda: >
|
||||
return range(1, 2)->map((_, v) => list[v])
|
||||
enddef
|
||||
|
||||
The same is true for commands that are not compiled, such as `:global`.
|
||||
For these the backtick expansion can be used. Example: >
|
||||
For commands that are not compiled, such as `:edit`, backtick expansion can be
|
||||
used and it can use the local scope. Example: >
|
||||
def Replace()
|
||||
var newText = 'blah'
|
||||
g/pattern/s/^/`=newText`/
|
||||
enddef
|
||||
|
||||
Or a script variable can be used: >
|
||||
var newText = 'blah'
|
||||
def Replace()
|
||||
g/pattern/s/^/\=newText/
|
||||
var fname = 'blah.txt'
|
||||
edit `=fname`
|
||||
enddef
|
||||
|
||||
Closures defined in a loop will share the same context. For example: >
|
||||
@@ -1163,8 +1177,6 @@ for each closure call a function to define it: >
|
||||
|
||||
4. Types *vim9-types*
|
||||
|
||||
THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE
|
||||
|
||||
The following builtin types are supported:
|
||||
bool
|
||||
number
|
||||
@@ -1345,8 +1357,6 @@ Same for |extend()|, use |extendnew()| instead, and for |flatten()|, use
|
||||
5. Namespace, Import and Export
|
||||
*vim9script* *vim9-export* *vim9-import*
|
||||
|
||||
THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE
|
||||
|
||||
A Vim9 script can be written to be imported. This means that everything in
|
||||
the script is local, unless exported. Those exported items, and only those
|
||||
items, can then be imported in another script.
|
||||
@@ -1381,6 +1391,7 @@ One of the effects is that |line-continuation| is always enabled.
|
||||
The original value of 'cpoptions' is restored at the end of the script, while
|
||||
flags added or removed in the script are also added to or removed from the
|
||||
original value to get the same effect. The order of flags may change.
|
||||
In the |vimrc| file sourced on startup this does not happen.
|
||||
|
||||
*vim9-mix*
|
||||
There is one way to use both legacy and Vim9 syntax in one script file: >
|
||||
@@ -1400,9 +1411,6 @@ This can only work in two ways:
|
||||
2. The "if" statement evaluates to true, the commands up to `endif` are
|
||||
executed and `finish` bails out before reaching `vim9script`.
|
||||
|
||||
TODO: The "vim9script" feature does not exist yet, it will only be added once
|
||||
the Vim9 script syntax has been fully implemented.
|
||||
|
||||
|
||||
Export ~
|
||||
*:export* *:exp*
|
||||
@@ -1660,7 +1668,8 @@ Specific items from TypeScript we avoid:
|
||||
- TypeScript can use an expression like "99 || 'yes'" in a condition, but
|
||||
cannot assign the value to a boolean. That is inconsistent and can be
|
||||
annoying. Vim recognizes an expression with && or || and allows using the
|
||||
result as a bool. TODO: to be reconsidered
|
||||
result as a bool. The |falsy-operator| was added for the mechanism to use a
|
||||
default value.
|
||||
- TypeScript considers an empty string as Falsy, but an empty list or dict as
|
||||
Truthy. That is inconsistent. In Vim an empty list and dict are also
|
||||
Falsy.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*visual.txt* For Vim version 8.2. Last change: 2021 May 30
|
||||
*visual.txt* For Vim version 8.2. Last change: 2021 Nov 21
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -370,7 +370,8 @@ same amount of text as the last time:
|
||||
last line the same number of characters as in the last line the last time.
|
||||
The start of the text is the Cursor position. If the "$" command was used as
|
||||
one of the last commands to extend the highlighted text, the repeating will
|
||||
be applied up to the rightmost column of the longest line.
|
||||
be applied up to the rightmost column of the longest line. Any count passed
|
||||
to the `.` command is not used.
|
||||
|
||||
|
||||
==============================================================================
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*windows.txt* For Vim version 8.2. Last change: 2021 Sep 09
|
||||
*windows.txt* For Vim version 8.2. Last change: 2021 Nov 29
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -1203,6 +1203,8 @@ list of buffers. |unlisted-buffer|
|
||||
the current buffer remains being edited. See |:buffer-!| for
|
||||
[!]. This will also edit a buffer that is not in the buffer
|
||||
list, without setting the 'buflisted' flag.
|
||||
The notation with single quotes does not work here,
|
||||
`:buf 12'345'` uses 12'345 as a buffer name.
|
||||
Also see |+cmd|.
|
||||
|
||||
:[N]b[uffer][!] [+cmd] {bufname} *{bufname}*
|
||||
@@ -1358,6 +1360,7 @@ directory Displays directory contents. Can be used by a file explorer
|
||||
< The buffer name is the name of the directory and is adjusted
|
||||
when using the |:cd| command.
|
||||
|
||||
*scratch-buffer*
|
||||
scratch Contains text that can be discarded at any time. It is kept
|
||||
when closing the window, it must be deleted explicitly.
|
||||
Settings: >
|
||||
|
||||
@@ -111,7 +111,7 @@ octets.
|
||||
.TP
|
||||
.IR \-p " | " \-ps " | " \-postscript " | " \-plain
|
||||
Produit une conversion continue dans le style Postscript (postscript continuous
|
||||
hexdumd style).
|
||||
hexdump style).
|
||||
<EFBFBD>galement connu sous le nom de <20> conversion brute <20> (plain hexdump style).
|
||||
.TP
|
||||
.IR \-r " | " \-revert
|
||||
|
||||
@@ -111,7 +111,7 @@ octets.
|
||||
.TP
|
||||
.IR \-p " | " \-ps " | " \-postscript " | " \-plain
|
||||
Produit une conversion continue dans le style Postscript (postscript continuous
|
||||
hexdumd style).
|
||||
hexdump style).
|
||||
Également connu sous le nom de « conversion brute » (plain hexdump style).
|
||||
.TP
|
||||
.IR \-r " | " \-revert
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim support file to detect file types
|
||||
"
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2021 Oct 03
|
||||
" Last Change: 2021 Dec 27
|
||||
|
||||
" Listen very carefully, I will say this only once
|
||||
if exists("did_load_filetypes")
|
||||
@@ -123,7 +123,7 @@ au BufNewFile,BufRead *.aml setf aml
|
||||
" APT config file
|
||||
au BufNewFile,BufRead apt.conf setf aptconf
|
||||
au BufNewFile,BufRead */.aptitude/config setf aptconf
|
||||
au BufNewFile,BufRead */etc/apt/apt.conf.d/{[-_[:alnum:]]\+,[-_.[:alnum:]]\+.conf} setf aptconf
|
||||
" more generic pattern far down
|
||||
|
||||
" Arch Inventory file
|
||||
au BufNewFile,BufRead .arch-inventory,=tagging-method setf arch
|
||||
@@ -260,7 +260,7 @@ au BufNewFile,BufRead *.lpc,*.ulpc setf lpc
|
||||
au BufNewFile,BufRead calendar setf calendar
|
||||
|
||||
" C#
|
||||
au BufNewFile,BufRead *.cs setf cs
|
||||
au BufNewFile,BufRead *.cs,*.csx setf cs
|
||||
|
||||
" CSDL
|
||||
au BufNewFile,BufRead *.csdl setf csdl
|
||||
@@ -397,6 +397,7 @@ au BufNewFile,BufRead configure.in,configure.ac setf config
|
||||
au BufNewFile,BufRead *.cu,*.cuh setf cuda
|
||||
|
||||
" Dockerfile; Podman uses the same syntax with name Containerfile
|
||||
" Also see Dockerfile.* below.
|
||||
au BufNewFile,BufRead Containerfile,Dockerfile,*.Dockerfile setf dockerfile
|
||||
|
||||
" WildPackets EtherPeek Decoder
|
||||
@@ -490,6 +491,9 @@ au BufNewFile,BufRead dict.conf,.dictrc setf dictconf
|
||||
" Dictd config
|
||||
au BufNewFile,BufRead dictd*.conf setf dictdconf
|
||||
|
||||
" DEP3 formatted patch files
|
||||
au BufNewFile,BufRead */debian/patches/* call dist#ft#Dep3patch()
|
||||
|
||||
" Diff files
|
||||
au BufNewFile,BufRead *.diff,*.rej setf diff
|
||||
au BufNewFile,BufRead *.patch
|
||||
@@ -617,6 +621,9 @@ autocmd BufRead,BufNewFile *.fnl setf fennel
|
||||
" Fetchmail RC file
|
||||
au BufNewFile,BufRead .fetchmailrc setf fetchmail
|
||||
|
||||
" Fish shell
|
||||
au BufNewFile,BufRead *.fish setf fish
|
||||
|
||||
" FlexWiki - disabled, because it has side effects when a .wiki file
|
||||
" is not actually FlexWiki
|
||||
"au BufNewFile,BufRead *.wiki setf flexwiki
|
||||
@@ -629,7 +636,7 @@ au BufNewFile,BufRead auto.master setf conf
|
||||
au BufNewFile,BufRead *.mas,*.master setf master
|
||||
|
||||
" Forth
|
||||
au BufNewFile,BufRead *.fs,*.ft,*.fth setf forth
|
||||
au BufNewFile,BufRead *.ft,*.fth setf forth
|
||||
|
||||
" Reva Forth
|
||||
au BufNewFile,BufRead *.frt setf reva
|
||||
@@ -646,8 +653,14 @@ au BufNewFile,BufRead *.fsl setf framescript
|
||||
" FStab
|
||||
au BufNewFile,BufRead fstab,mtab setf fstab
|
||||
|
||||
" F# or Forth
|
||||
au BufNewFile,BufRead *.fs call dist#ft#FTfs()
|
||||
|
||||
" F#
|
||||
au BufNewFile,BufRead *.fsi,*.fsx setf fsharp
|
||||
|
||||
" GDB command files
|
||||
au BufNewFile,BufRead .gdbinit setf gdb
|
||||
au BufNewFile,BufRead .gdbinit,gdbinit setf gdb
|
||||
|
||||
" GDMO
|
||||
au BufNewFile,BufRead *.mo,*.gdmo setf gdmo
|
||||
@@ -781,6 +794,10 @@ au BufNewFile,BufRead *.hb setf hb
|
||||
" Httest
|
||||
au BufNewFile,BufRead *.htt,*.htb setf httest
|
||||
|
||||
" i3 (and sway)
|
||||
au BufNewFile,BufRead */i3/config,*/sway/config setf i3config
|
||||
au BufNewFile,BufRead */.i3/config,*/.sway/config setf i3config
|
||||
|
||||
" Icon
|
||||
au BufNewFile,BufRead *.icn setf icon
|
||||
|
||||
@@ -946,9 +963,9 @@ au BufNewFile,BufRead lilo.conf setf lilo
|
||||
" Lisp (*.el = ELisp, *.cl = Common Lisp)
|
||||
" *.jl was removed, it's also used for Julia, better skip than guess wrong.
|
||||
if has("fname_case")
|
||||
au BufNewFile,BufRead *.lsp,*.lisp,*.el,*.cl,*.L,.emacs,.sawfishrc setf lisp
|
||||
au BufNewFile,BufRead *.lsp,*.lisp,*.asd,*.el,*.cl,*.L,.emacs,.sawfishrc setf lisp
|
||||
else
|
||||
au BufNewFile,BufRead *.lsp,*.lisp,*.el,*.cl,.emacs,.sawfishrc setf lisp
|
||||
au BufNewFile,BufRead *.lsp,*.lisp,*.asd,*.el,*.cl,.emacs,.sawfishrc setf lisp
|
||||
endif
|
||||
|
||||
" SBCL implementation of Common Lisp
|
||||
@@ -1075,7 +1092,9 @@ au BufNewFile,BufRead *.mmp setf mmp
|
||||
|
||||
" Modsim III (or LambdaProlog)
|
||||
au BufNewFile,BufRead *.mod
|
||||
\ if getline(1) =~ '\<module\>' |
|
||||
\ if expand("<afile>") =~ '\<go.mod$' |
|
||||
\ setf gomod |
|
||||
\ elseif getline(1) =~ '\<module\>' |
|
||||
\ setf lprolog |
|
||||
\ else |
|
||||
\ setf modsim3 |
|
||||
@@ -1114,14 +1133,15 @@ au BufNewFile,BufRead *.msql setf msql
|
||||
" Mysql
|
||||
au BufNewFile,BufRead *.mysql setf mysql
|
||||
|
||||
" Mutt setup files (must be before catch *.rc)
|
||||
au BufNewFile,BufRead */etc/Muttrc.d/* call s:StarSetf('muttrc')
|
||||
|
||||
" Tcl Shell RC file
|
||||
au BufNewFile,BufRead tclsh.rc setf tcl
|
||||
|
||||
" M$ Resource files
|
||||
au BufNewFile,BufRead *.rc,*.rch setf rc
|
||||
" /etc/Muttrc.d/file.rc is muttrc
|
||||
au BufNewFile,BufRead *.rc,*.rch
|
||||
\ if expand("<afile>") !~ "/etc/Muttrc.d/" |
|
||||
\ setf rc |
|
||||
\ endif
|
||||
|
||||
" MuPAD source
|
||||
au BufRead,BufNewFile *.mu setf mupad
|
||||
@@ -1493,6 +1513,9 @@ au BufNewFile,BufRead robots.txt setf robots
|
||||
" Rpcgen
|
||||
au BufNewFile,BufRead *.x setf rpcgen
|
||||
|
||||
" MikroTik RouterOS script
|
||||
au BufRead,BufNewFile *.rsc setf routeros
|
||||
|
||||
" reStructuredText Documentation Format
|
||||
au BufNewFile,BufRead *.rst setf rst
|
||||
|
||||
@@ -1637,13 +1660,16 @@ au BufNewFile,BufRead .tcshrc,*.tcsh,tcsh.tcshrc,tcsh.login call dist#ft#SetFile
|
||||
" (patterns ending in a start further below)
|
||||
au BufNewFile,BufRead .login,.cshrc,csh.cshrc,csh.login,csh.logout,*.csh,.alias call dist#ft#CSH()
|
||||
|
||||
" Zig
|
||||
au BufNewFile,BufRead *.zig setf zig
|
||||
|
||||
" Z-Shell script (patterns ending in a star further below)
|
||||
au BufNewFile,BufRead .zprofile,*/etc/zprofile,.zfbfmarks setf zsh
|
||||
au BufNewFile,BufRead .zshrc,.zshenv,.zlogin,.zlogout,.zcompdump setf zsh
|
||||
au BufNewFile,BufRead *.zsh setf zsh
|
||||
|
||||
" Scheme
|
||||
au BufNewFile,BufRead *.scm,*.ss,*.rkt,*.rktd,*.rktl setf scheme
|
||||
au BufNewFile,BufRead *.scm,*.ss,*.sld,*.rkt,*.rktd,*.rktl setf scheme
|
||||
|
||||
" Screen RC
|
||||
au BufNewFile,BufRead .screenrc,screenrc setf screen
|
||||
@@ -1723,6 +1749,10 @@ au BufNewFile,BufRead *.speedup,*.spdata,*.spd setf spup
|
||||
" Slice
|
||||
au BufNewFile,BufRead *.ice setf slice
|
||||
|
||||
" Microsoft Visual Studio Solution
|
||||
au BufNewFile,BufRead *.sln setf solution
|
||||
au BufNewFile,BufRead *.slnf setf json
|
||||
|
||||
" Spice
|
||||
au BufNewFile,BufRead *.sp,*.spice setf spice
|
||||
|
||||
@@ -1744,9 +1774,12 @@ au BufNewFile,BufRead *.sqlj setf sqlj
|
||||
" SQR
|
||||
au BufNewFile,BufRead *.sqr,*.sqi setf sqr
|
||||
|
||||
" Squirrel
|
||||
au BufNewFile,BufRead *.nut setf squirrel
|
||||
|
||||
" OpenSSH configuration
|
||||
au BufNewFile,BufRead ssh_config,*/.ssh/config setf sshconfig
|
||||
au BufNewFile,BufRead */etc/ssh/ssh_config.d/*.conf setf sshconfig
|
||||
au BufNewFile,BufRead ssh_config,*/.ssh/config,*/.ssh/*.conf setf sshconfig
|
||||
au BufNewFile,BufRead */etc/ssh/ssh_config.d/*.conf setf sshconfig
|
||||
|
||||
" OpenSSH server configuration
|
||||
au BufNewFile,BufRead sshd_config setf sshdconfig
|
||||
@@ -2053,9 +2086,15 @@ au BufNewFile,BufRead *.xml call dist#ft#FTxml()
|
||||
" XMI (holding UML models) is also XML
|
||||
au BufNewFile,BufRead *.xmi setf xml
|
||||
|
||||
" CSPROJ files are Visual Studio.NET's XML-based project config files
|
||||
" CSPROJ files are Visual Studio.NET's XML-based C# project config files
|
||||
au BufNewFile,BufRead *.csproj,*.csproj.user setf xml
|
||||
|
||||
" FSPROJ files are Visual Studio.NET's XML-based F# project config files
|
||||
au BufNewFile,BufRead *.fsproj,*.fsproj.user setf xml
|
||||
|
||||
" VBPROJ files are Visual Studio.NET's XML-based Visual Basic project config files
|
||||
au BufNewFile,BufRead *.vbproj,*.vbproj.user setf xml
|
||||
|
||||
" Qt Linguist translation source and Qt User Interface Files are XML
|
||||
" However, for .ts Typescript is more common.
|
||||
au BufNewFile,BufRead *.ui setf xml
|
||||
@@ -2141,6 +2180,12 @@ au BufNewFile,BufRead *
|
||||
au StdinReadPost * if !did_filetype() | runtime! scripts.vim | endif
|
||||
|
||||
|
||||
" Plain text files, needs to be far down to not override others. This avoids
|
||||
" the "conf" type being used if there is a line starting with '#'.
|
||||
" But before patterns matching everything in a directory.
|
||||
au BufNewFile,BufRead *.text,README,LICENSE,COPYING,AUTHORS setf text
|
||||
|
||||
|
||||
" Extra checks for when no filetype has been detected now. Mostly used for
|
||||
" patterns that end in "*". E.g., "zsh*" matches "zsh.vim", but that's a Vim
|
||||
" script file.
|
||||
@@ -2155,6 +2200,9 @@ au BufNewFile,BufRead proftpd.conf* call s:StarSetf('apachestyle')
|
||||
au BufNewFile,BufRead access.conf*,apache.conf*,apache2.conf*,httpd.conf*,srm.conf* call s:StarSetf('apache')
|
||||
au BufNewFile,BufRead */etc/apache2/*.conf*,*/etc/apache2/conf.*/*,*/etc/apache2/mods-*/*,*/etc/apache2/sites-*/*,*/etc/httpd/conf.*/*,*/etc/httpd/mods-*/*,*/etc/httpd/sites-*/*,*/etc/httpd/conf.d/*.conf* call s:StarSetf('apache')
|
||||
|
||||
" APT config file
|
||||
au BufNewFile,BufRead */etc/apt/apt.conf.d/{[-_[:alnum:]]\+,[-_.[:alnum:]]\+.conf} call s:StarSetf('aptconf')
|
||||
|
||||
" Asterisk config file
|
||||
au BufNewFile,BufRead *asterisk/*.conf* call s:StarSetf('asterisk')
|
||||
au BufNewFile,BufRead *asterisk*/*voicemail.conf* call s:StarSetf('asteriskvm')
|
||||
@@ -2191,6 +2239,9 @@ au BufNewFile,BufRead crontab,crontab.*,*/etc/cron.d/* call s:StarSetf('crontab
|
||||
" dnsmasq(8) configuration
|
||||
au BufNewFile,BufRead */etc/dnsmasq.d/* call s:StarSetf('dnsmasq')
|
||||
|
||||
" Dockerfile
|
||||
au BufNewFile,BufRead Dockerfile.*,Containerfile.* call s:StarSetf('dockerfile')
|
||||
|
||||
" Dracula
|
||||
au BufNewFile,BufRead drac.* call s:StarSetf('dracula')
|
||||
|
||||
@@ -2256,6 +2307,9 @@ au BufNewFile,BufRead */etc/modutils/*
|
||||
\|endif
|
||||
au BufNewFile,BufRead */etc/modprobe.* call s:StarSetf('modconf')
|
||||
|
||||
" Mutt setup files (must be before catch *.rc)
|
||||
au BufNewFile,BufRead */etc/Muttrc.d/* call s:StarSetf('muttrc')
|
||||
|
||||
" Mutt setup file
|
||||
au BufNewFile,BufRead .mutt{ng,}rc*,*/.mutt{ng,}/mutt{ng,}rc* call s:StarSetf('muttrc')
|
||||
au BufNewFile,BufRead mutt{ng,}rc*,Mutt{ng,}rc* call s:StarSetf('muttrc')
|
||||
@@ -2301,6 +2355,9 @@ au BufNewFile,BufRead .bashrc*,.bash[_-]profile*,.bash[_-]logout*,.bash[_-]alias
|
||||
au BufNewFile,BufRead .kshrc* call dist#ft#SetFileTypeSH("ksh")
|
||||
au BufNewFile,BufRead .profile* call dist#ft#SetFileTypeSH(getline(1))
|
||||
|
||||
" Sudoers
|
||||
au BufNewFile,BufRead */etc/sudoers.d/* call s:StarSetf('sudoers')
|
||||
|
||||
" tcsh scripts ending in a star
|
||||
au BufNewFile,BufRead .tcshrc* call dist#ft#SetFileTypeShell("tcsh")
|
||||
|
||||
@@ -2345,10 +2402,6 @@ au BufNewFile,BufRead .zsh*,.zlog*,.zcompdump* call s:StarSetf('zsh')
|
||||
au BufNewFile,BufRead zsh*,zlog* call s:StarSetf('zsh')
|
||||
|
||||
|
||||
" Plain text files, needs to be far down to not override others. This avoids
|
||||
" the "conf" type being used if there is a line starting with '#'.
|
||||
au BufNewFile,BufRead *.text,README setf text
|
||||
|
||||
" Help files match *.txt but should have a last line that is a modeline.
|
||||
au BufNewFile,BufRead *.txt
|
||||
\ if getline('$') !~ 'vim:.*ft=help'
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Aap recipe
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2013 Apr 05
|
||||
" Last Change: 2021 Nov 14
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -11,8 +11,9 @@ endif
|
||||
" Don't load another plugin for this buffer
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
" Reset 'formatoptions', 'comments' and 'expandtab' to undo this plugin.
|
||||
let b:undo_ftplugin = "setl fo< com< et<"
|
||||
" Reset 'formatoptions', 'comments', 'commentstring' and 'expandtab' to undo
|
||||
" this plugin.
|
||||
let b:undo_ftplugin = "setl fo< com< cms< et<"
|
||||
|
||||
" Set 'formatoptions' to break comment lines but not other lines,
|
||||
" and insert the comment leader when hitting <CR> or using "o".
|
||||
@@ -20,6 +21,12 @@ setlocal fo-=t fo+=croql
|
||||
|
||||
" Set 'comments' to format dashed lists in comments.
|
||||
setlocal comments=s:#\ -,m:#\ \ ,e:#,n:#,fb:-
|
||||
setlocal commentstring=#\ %s
|
||||
|
||||
" Expand tabs to spaces to avoid trouble.
|
||||
setlocal expandtab
|
||||
|
||||
if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
|
||||
let b:browsefilter = "Aap Recipe Files (*.aap)\t*.aap\nAll Files (*.*)\t*.*\n"
|
||||
let b:undo_ftplugin ..= " | unlet! b:browsefilter"
|
||||
endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
" Language: generic Changelog file
|
||||
" Maintainer: Martin Florian <marfl@posteo.de>
|
||||
" Previous Maintainer: Nikolai Weibull <now@bitwi.se>
|
||||
" Latest Revision: 2015-10-25
|
||||
" Latest Revision: 2021-10-17
|
||||
" Variables:
|
||||
" g:changelog_timeformat (deprecated: use g:changelog_dateformat instead) -
|
||||
" description: the timeformat used in ChangeLog entries.
|
||||
@@ -55,7 +55,7 @@ if &filetype == 'changelog'
|
||||
elseif $EMAIL_ADDRESS != ""
|
||||
return $EMAIL_ADDRESS
|
||||
endif
|
||||
|
||||
|
||||
let login = s:login()
|
||||
return printf('%s <%s@%s>', s:name(login), login, s:hostname())
|
||||
endfunction
|
||||
@@ -223,12 +223,6 @@ if &filetype == 'changelog'
|
||||
let &paste = save_paste
|
||||
endfunction
|
||||
|
||||
if exists(":NewChangelogEntry") != 2
|
||||
nnoremap <buffer> <silent> <Leader>o :<C-u>call <SID>new_changelog_entry('')<CR>
|
||||
xnoremap <buffer> <silent> <Leader>o :<C-u>call <SID>new_changelog_entry('')<CR>
|
||||
command! -nargs=0 NewChangelogEntry call s:new_changelog_entry('')
|
||||
endif
|
||||
|
||||
let b:undo_ftplugin = "setl com< fo< et< ai<"
|
||||
|
||||
setlocal comments=
|
||||
@@ -241,14 +235,26 @@ if &filetype == 'changelog'
|
||||
let b:undo_ftplugin .= " tw<"
|
||||
endif
|
||||
|
||||
if !exists("no_plugin_maps") && !exists("no_changelog_maps") && exists(":NewChangelogEntry") != 2
|
||||
nnoremap <buffer> <silent> <Leader>o :<C-u>call <SID>new_changelog_entry('')<CR>
|
||||
xnoremap <buffer> <silent> <Leader>o :<C-u>call <SID>new_changelog_entry('')<CR>
|
||||
command! -buffer -nargs=0 NewChangelogEntry call s:new_changelog_entry('')
|
||||
let b:undo_ftplugin .= " | sil! exe 'nunmap <buffer> <Leader>o'" .
|
||||
\ " | sil! exe 'vunmap <buffer> <Leader>o'" .
|
||||
\ " | sil! delc NewChangelogEntry"
|
||||
endif
|
||||
|
||||
let &cpo = s:cpo_save
|
||||
unlet s:cpo_save
|
||||
else
|
||||
let s:cpo_save = &cpo
|
||||
set cpo&vim
|
||||
|
||||
" Add the Changelog opening mapping
|
||||
nnoremap <silent> <Leader>o :call <SID>open_changelog()<CR>
|
||||
if !exists("no_plugin_maps") && !exists("no_changelog_maps")
|
||||
" Add the Changelog opening mapping
|
||||
nnoremap <silent> <Leader>o :call <SID>open_changelog()<CR>
|
||||
let b:undo_ftplugin .= " | silent! exe 'nunmap <buffer> <Leader>o"
|
||||
endif
|
||||
|
||||
function! s:open_changelog()
|
||||
let path = expand('%:p:h')
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Clojure
|
||||
" Maintainer: Alex Vear <av@axvr.io>
|
||||
" Maintainer: Alex Vear <alex@vear.uk>
|
||||
" Former Maintainers: Sung Pae <self@sungpae.com>
|
||||
" Meikel Brandmeyer <mb@kotka.de>
|
||||
" URL: https://github.com/clojure-vim/clojure.vim
|
||||
" License: Vim (see :h license)
|
||||
" Last Change: 2021-02-13
|
||||
" Last Change: 2021-10-26
|
||||
|
||||
if exists("b:did_ftplugin")
|
||||
finish
|
||||
@@ -17,7 +17,7 @@ set cpo&vim
|
||||
|
||||
let b:undo_ftplugin = 'setlocal iskeyword< define< formatoptions< comments< commentstring< lispwords<'
|
||||
|
||||
setlocal iskeyword+=?,-,*,!,+,/,=,<,>,.,:,$
|
||||
setlocal iskeyword+=?,-,*,!,+,/,=,<,>,.,:,$,%,&,\|
|
||||
|
||||
" There will be false positives, but this is better than missing the whole set
|
||||
" of user-defined def* definitions.
|
||||
@@ -43,7 +43,7 @@ setlocal commentstring=;\ %s
|
||||
" specially and hence are not indented specially.
|
||||
"
|
||||
" -*- LISPWORDS -*-
|
||||
" Generated from https://github.com/clojure-vim/clojure.vim/blob/f8594e7030cdfb0b7990ac92953c77a08a7220f0/clj/src/vim_clojure_static/generate.clj
|
||||
" Generated from https://github.com/clojure-vim/clojure.vim/blob/62b215f079ce0f3834fd295c7a7f6bd8cc54bcc3/clj/src/vim_clojure_static/generate.clj
|
||||
setlocal lispwords=as->,binding,bound-fn,case,catch,cond->,cond->>,condp,def,definline,definterface,defmacro,defmethod,defmulti,defn,defn-,defonce,defprotocol,defrecord,defstruct,deftest,deftest-,deftype,doseq,dotimes,doto,extend,extend-protocol,extend-type,fn,for,if,if-let,if-not,if-some,let,letfn,locking,loop,ns,proxy,reify,set-test,testing,when,when-first,when-let,when-not,when-some,while,with-bindings,with-in-str,with-local-vars,with-open,with-precision,with-redefs,with-redefs-fn,with-test
|
||||
|
||||
" Provide insert mode completions for special forms and clojure.core. As
|
||||
@@ -64,8 +64,8 @@ if exists('loaded_matchit')
|
||||
let b:undo_ftplugin .= ' | unlet! b:match_words b:match_skip'
|
||||
endif
|
||||
|
||||
" Win32 can filter files in the browse dialog
|
||||
if has("gui_win32") && !exists("b:browsefilter")
|
||||
" Filter files in the browse dialog
|
||||
if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
|
||||
let b:browsefilter = "Clojure Source Files (*.clj)\t*.clj\n" .
|
||||
\ "ClojureScript Source Files (*.cljs)\t*.cljs\n" .
|
||||
\ "Java Source Files (*.java)\t*.java\n" .
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Diff
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2020 Jul 18
|
||||
" Last Change: 2021 Nov 14
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -9,10 +9,15 @@ if exists("b:did_ftplugin")
|
||||
endif
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
let b:undo_ftplugin = "setl modeline<"
|
||||
let b:undo_ftplugin = "setl modeline< commentstring<"
|
||||
|
||||
" Don't use modelines in a diff, they apply to the diffed file
|
||||
setlocal nomodeline
|
||||
|
||||
" If there are comments they start with #
|
||||
let &commentstring = "# %s"
|
||||
let &l:commentstring = "# %s"
|
||||
|
||||
if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
|
||||
let b:browsefilter = "Diff Files (*.diff)\t*.diff\nPatch Files (*.patch)\t*.h\nAll Files (*.*)\t*.*\n"
|
||||
let b:undo_ftplugin ..= " | unlet! b:browsefilter"
|
||||
endif
|
||||
|
||||
13
runtime/ftplugin/i3config.vim
Normal file
13
runtime/ftplugin/i3config.vim
Normal file
@@ -0,0 +1,13 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: i3 config file
|
||||
" Original Author: Mohamed Boughaba <mohamed dot bgb at gmail dot com>
|
||||
" Maintainer: Quentin Hibon
|
||||
" Version: 0.4
|
||||
" Last Change: 2021 Dec 14
|
||||
|
||||
if exists("b:did_ftplugin") | finish | endif
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
let b:undo_ftplugin = "setlocal cms<"
|
||||
|
||||
setlocal commentstring=#\ %s
|
||||
@@ -1,7 +1,8 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: indent(1) configuration file
|
||||
" Previous Maintainer: Nikolai Weibull <now@bitwi.se>
|
||||
" Latest Revision: 2008-07-09
|
||||
" Language: indent(1) configuration file
|
||||
" Maintainer: Doug Kearns <dougkearns@gmail.com>
|
||||
" Previous Maintainer: Nikolai Weibull <now@bitwi.se>
|
||||
" Latest Revision: 2008-07-09
|
||||
|
||||
if exists("b:did_ftplugin")
|
||||
finish
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
" Acknowledgement: Based off of vim-jsonc maintained by Kevin Locke <kevin@kevinlocke.name>
|
||||
" https://github.com/kevinoid/vim-jsonc
|
||||
" License: MIT
|
||||
" Last Change: 2021-07-01
|
||||
" Last Change: 2021 Nov 22
|
||||
|
||||
runtime! ftplugin/json.vim
|
||||
|
||||
@@ -14,14 +14,8 @@ else
|
||||
let b:did_ftplugin_jsonc = 1
|
||||
endif
|
||||
|
||||
" A list of commands that undo buffer local changes made below.
|
||||
let s:undo_ftplugin = []
|
||||
|
||||
" Set comment (formatting) related options. {{{1
|
||||
setlocal commentstring=//%s comments=sO:*\ -,mO:*\ \ ,exO:*/,s1:/*,mb:*,ex:*/,://
|
||||
call add(s:undo_ftplugin, 'commentstring< comments<')
|
||||
|
||||
" Let Vim know how to disable the plug-in.
|
||||
call map(s:undo_ftplugin, "'execute ' . string(v:val)")
|
||||
let b:undo_ftplugin = join(s:undo_ftplugin, ' | ')
|
||||
unlet s:undo_ftplugin
|
||||
let b:undo_ftplugin = 'setlocal commentstring< comments<'
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
" Vim filetype plugin file.
|
||||
" Language: Lua 4.0+
|
||||
" Maintainer: Max Ischenko <mfi@ukr.net>
|
||||
" Last Change: 2012 Mar 07
|
||||
" Language: Lua
|
||||
" Maintainer: Doug Kearns <dougkearns@gmail.com>
|
||||
" Previous Maintainer: Max Ischenko <mfi@ukr.net>
|
||||
" Last Change: 2021 Nov 15
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -16,27 +17,30 @@ set cpo&vim
|
||||
|
||||
" Set 'formatoptions' to break comment lines but not other lines, and insert
|
||||
" the comment leader when hitting <CR> or using "o".
|
||||
setlocal fo-=t fo+=croql
|
||||
setlocal formatoptions-=t formatoptions+=croql
|
||||
|
||||
setlocal com=:--
|
||||
setlocal cms=--%s
|
||||
setlocal comments=:--
|
||||
setlocal commentstring=--%s
|
||||
setlocal suffixesadd=.lua
|
||||
|
||||
let b:undo_ftplugin = "setlocal fo< com< cms< sua<"
|
||||
|
||||
" The following lines enable the macros/matchit.vim plugin for
|
||||
" extended matching with the % key.
|
||||
if exists("loaded_matchit")
|
||||
|
||||
if exists("loaded_matchit") && !exists("b:match_words")
|
||||
let b:match_ignorecase = 0
|
||||
let b:match_words =
|
||||
\ '\<\%(do\|function\|if\)\>:' .
|
||||
\ '\<\%(return\|else\|elseif\)\>:' .
|
||||
\ '\<end\>,' .
|
||||
\ '\<repeat\>:\<until\>'
|
||||
\ '\<\%(do\|function\|if\)\>:' .
|
||||
\ '\<\%(return\|else\|elseif\)\>:' .
|
||||
\ '\<end\>,' .
|
||||
\ '\<repeat\>:\<until\>,' .
|
||||
\ '\%(--\)\=\[\(=*\)\[:]\1]'
|
||||
let b:undo_ftplugin .= " | unlet! b:match_words b:match_ignorecase"
|
||||
endif
|
||||
|
||||
endif " exists("loaded_matchit")
|
||||
if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
|
||||
let b:browsefilter = "Lua Source Files (*.lua)\t*.lua\n" .
|
||||
\ "All Files (*.*)\t*.*\n"
|
||||
let b:undo_ftplugin .= " | unlet! b:browsefilter"
|
||||
endif
|
||||
|
||||
let &cpo = s:cpo_save
|
||||
unlet s:cpo_save
|
||||
|
||||
let b:undo_ftplugin = "setlocal fo< com< cms< suffixesadd<"
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Mail
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2012 Nov 20
|
||||
" Last Change: 2021 Oct 23
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -26,6 +26,14 @@ setlocal fo+=tcql
|
||||
" Add n:> to 'comments, in case it was removed elsewhere
|
||||
setlocal comments+=n:>
|
||||
|
||||
" .eml files are universally formatted with DOS line-endings, per RFC5322.
|
||||
" If the file was not DOS the it will be marked as changed, which is probably
|
||||
" a good thing.
|
||||
if expand('%:e') ==? 'eml'
|
||||
let b:undo_ftplugin ..= " fileformat=" .. &fileformat
|
||||
setlocal fileformat=dos
|
||||
endif
|
||||
|
||||
" Add mappings, unless the user doesn't want this.
|
||||
if !exists("no_plugin_maps") && !exists("no_mail_maps")
|
||||
" Quote text by inserting "> "
|
||||
|
||||
@@ -12,9 +12,28 @@ set cpo&vim
|
||||
|
||||
setlocal commentstring=#\ %s
|
||||
setlocal comments=:#
|
||||
setlocal formatoptions+=croql formatoptions-=t
|
||||
|
||||
setlocal shiftwidth=2
|
||||
setlocal softtabstop=2
|
||||
let b:undo_ftplugin = "setl com< cms< fo<"
|
||||
|
||||
if get(g:, "meson_recommended_style", 1)
|
||||
setlocal expandtab
|
||||
setlocal shiftwidth=2
|
||||
setlocal softtabstop=2
|
||||
let b:undo_ftplugin .= " | setl et< sts< sw<"
|
||||
endif
|
||||
|
||||
if exists("loaded_matchit") && !exists("b:match_words")
|
||||
let b:match_words = '\<if\>:\<elif\>:\<else\>:\<endif\>,' .
|
||||
\ '\<foreach\>:\<break\>:\<continue\>:\<endforeach\>'
|
||||
let b:undo_ftplugin .= " | unlet! b:match_words"
|
||||
endif
|
||||
|
||||
if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
|
||||
let b:browsefilter = "Meson Build Files (meson.build)\tmeson.build\n" .
|
||||
\ "All Files (*.*)\t*.*\n"
|
||||
let b:undo_ftplugin .= " | unlet! b:browsefilter"
|
||||
endif
|
||||
|
||||
let &cpo = s:keepcpo
|
||||
unlet s:keepcpo
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
" Maintainer: Ken Takata
|
||||
" URL: https://github.com/k-takata/vim-nsis
|
||||
" Previous Maintainer: Nikolai Weibull <now@bitwi.se>
|
||||
" Last Change: 2018-01-26
|
||||
" Last Change: 2021-10-18
|
||||
|
||||
if exists("b:did_ftplugin")
|
||||
finish
|
||||
@@ -15,7 +15,6 @@ set cpo&vim
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
let b:undo_ftplugin = "setl com< cms< fo< def< inc<"
|
||||
\ " | unlet! b:match_ignorecase b:match_words"
|
||||
|
||||
setlocal comments=s1:/*,mb:*,ex:*/,b:#,:; commentstring=;\ %s
|
||||
setlocal formatoptions-=t formatoptions+=croql
|
||||
@@ -37,6 +36,7 @@ if exists("loaded_matchit")
|
||||
\ '\${MementoSection}:\${MementoSectionEnd},' .
|
||||
\ '!if\%(\%(macro\)\?n\?def\)\?\>:!else\>:!endif\>,' .
|
||||
\ '!macro\>:!macroend\>'
|
||||
let b:undo_ftplugin .= " | unlet! b:match_ignorecase b:match_words"
|
||||
endif
|
||||
|
||||
let &cpo = s:cpo_save
|
||||
|
||||
29
runtime/ftplugin/routeros.vim
Normal file
29
runtime/ftplugin/routeros.vim
Normal file
@@ -0,0 +1,29 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: MikroTik RouterOS Script
|
||||
" Maintainer: zainin <z@wintr.dev>
|
||||
" Last Change: 2021 Nov 14
|
||||
|
||||
if exists("b:did_ftplugin")
|
||||
finish
|
||||
endif
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
let s:save_cpo = &cpo
|
||||
set cpo-=C
|
||||
|
||||
setlocal comments=:#
|
||||
setlocal commentstring=#\ %s
|
||||
setlocal formatoptions-=t formatoptions+=croql
|
||||
|
||||
let b:undo_ftplugin = "setlocal com< cms< fo<"
|
||||
|
||||
if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
|
||||
let b:browsefilter = "RouterOS Script Files (*.rsc)\t*.rsc\n" ..
|
||||
\ "All Files (*.*)\t*.*\n"
|
||||
let b:undo_ftplugin ..= " | unlet! b:browsefilter"
|
||||
endif
|
||||
|
||||
let &cpo = s:save_cpo
|
||||
unlet! s:save_cpo
|
||||
|
||||
" vim: nowrap sw=2 sts=2 ts=8 noet:
|
||||
37
runtime/ftplugin/solution.vim
Normal file
37
runtime/ftplugin/solution.vim
Normal file
@@ -0,0 +1,37 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Microsoft Visual Studio Solution
|
||||
" Maintainer: Doug Kearns <dougkearns@gmail.com>
|
||||
" Last Change: 2021 Dec 15
|
||||
|
||||
if exists("b:did_ftplugin")
|
||||
finish
|
||||
endif
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
let s:cpo_save = &cpo
|
||||
set cpo&vim
|
||||
|
||||
setlocal comments=:#
|
||||
setlocal commentstring=#\ %s
|
||||
|
||||
let b:undo_ftplugin = "setl com< cms<"
|
||||
|
||||
if exists("loaded_matchit") && !exists("b:match_words")
|
||||
let b:match_words =
|
||||
\ '\<Project\>:\<EndProject\>,' ..
|
||||
\ '\<ProjectSection\>:\<EndProjectSection\>,' ..
|
||||
\ '\<Global\>:\<EndGlobal\>,' ..
|
||||
\ '\<GlobalSection\>:\<EndGlobalSection\>'
|
||||
let b:undo_ftplugin ..= " | unlet! b:match_words"
|
||||
endif
|
||||
|
||||
if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
|
||||
let b:browsefilter = "Microsoft Visual Studio Solution Files\t*.sln\n" ..
|
||||
\ "All Files (*.*)\t*.*\n"
|
||||
let b:undo_ftplugin ..= " | unlet! b:browsefilter"
|
||||
endif
|
||||
|
||||
let &cpo = s:cpo_save
|
||||
unlet s:cpo_save
|
||||
|
||||
" vim: nowrap sw=2 sts=2 ts=8 noet:
|
||||
@@ -18,8 +18,8 @@ if !exists("no_plugin_maps") && !exists("no_spec_maps")
|
||||
endif
|
||||
endif
|
||||
|
||||
if !hasmapto("call SpecChangelog(\"\")<CR>")
|
||||
noremap <buffer> <unique> <script> <Plug>SpecChangelog :call SpecChangelog("")<CR>
|
||||
if !hasmapto("call <SID>SpecChangelog(\"\")<CR>")
|
||||
noremap <buffer> <unique> <script> <Plug>SpecChangelog :call <SID>SpecChangelog("")<CR>
|
||||
endif
|
||||
|
||||
if !exists("*s:GetRelVer")
|
||||
|
||||
@@ -1,44 +1,70 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: VisualBasic (ft=vb)
|
||||
" Maintainer: Johannes Zellner <johannes@zellner.org>
|
||||
" Last Change: Thu, 22 Nov 2001 12:56:14 W. Europe Standard Time
|
||||
" Language: Visual Basic (ft=vb)
|
||||
" Maintainer: Doug Kearns <dougkearns@gmail.com>
|
||||
" Previous Maintainer: Johannes Zellner <johannes@zellner.org>
|
||||
" Last Change: 2021 Nov 17
|
||||
|
||||
if exists("b:did_ftplugin") | finish | endif
|
||||
if exists("b:did_ftplugin")
|
||||
finish
|
||||
endif
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
setlocal com=sr:'\ -,mb:'\ \ ,el:'\ \ ,:'
|
||||
let s:cpo_save = &cpo
|
||||
set cpo&vim
|
||||
|
||||
setlocal comments=sr:'\ -,mb:'\ \ ,el:'\ \ ,:'
|
||||
setlocal commentstring='\ %s
|
||||
setlocal formatoptions-=t formatoptions+=croql
|
||||
|
||||
let b:undo_ftplugin = "setlocal com< cms< fo<"
|
||||
|
||||
" we need this wrapper, as call doesn't allow a count
|
||||
fun! <SID>VbSearch(pattern, flags)
|
||||
function! s:VbSearch(pattern, flags)
|
||||
let cnt = v:count1
|
||||
while cnt > 0
|
||||
call search(a:pattern, a:flags)
|
||||
let cnt = cnt - 1
|
||||
endwhile
|
||||
endfun
|
||||
endfunction
|
||||
|
||||
let s:cpo_save = &cpo
|
||||
set cpo&vim
|
||||
if !exists("no_plugin_maps") && !exists("no_vb_maps")
|
||||
nnoremap <buffer> <silent> [[ <Cmd>call <SID>VbSearch('^\s*\%(\%(private\<Bar>public\)\s\+\)\=\%(function\<Bar>sub\)', 'sbW')<CR>
|
||||
vnoremap <buffer> <silent> [[ <Cmd>call <SID>VbSearch('^\s*\%(\%(private\<Bar>public\)\s\+\)\=\%(function\<Bar>sub\)', 'sbW')<CR>
|
||||
nnoremap <buffer> <silent> ]] <Cmd>call <SID>VbSearch('^\s*\%(\%(private\<Bar>public\)\s\+\)\=\%(function\<Bar>sub\)', 'sW')<CR>
|
||||
vnoremap <buffer> <silent> ]] <Cmd>call <SID>VbSearch('^\s*\%(\%(private\<Bar>public\)\s\+\)\=\%(function\<Bar>sub\)', 'sW')<CR>
|
||||
nnoremap <buffer> <silent> [] <Cmd>call <SID>VbSearch('^\s*end\s\+\%(function\<Bar>sub\)', 'sbW')<CR>
|
||||
vnoremap <buffer> <silent> [] <Cmd>call <SID>VbSearch('^\s*end\s\+\%(function\<Bar>sub\)', 'sbW')<CR>
|
||||
nnoremap <buffer> <silent> ][ <Cmd>call <SID>VbSearch('^\s*end\s\+\%(function\<Bar>sub\)', 'sW')<CR>
|
||||
vnoremap <buffer> <silent> ][ <Cmd>call <SID>VbSearch('^\s*end\s\+\%(function\<Bar>sub\)', 'sW')<CR>
|
||||
let b:undo_ftplugin .= " | sil! exe 'nunmap <buffer> [[' | sil! exe 'vunmap <buffer> [['" .
|
||||
\ " | sil! exe 'nunmap <buffer> ]]' | sil! exe 'vunmap <buffer> ]]'" .
|
||||
\ " | sil! exe 'nunmap <buffer> []' | sil! exe 'vunmap <buffer> []'" .
|
||||
\ " | sil! exe 'nunmap <buffer> ][' | sil! exe 'vunmap <buffer> ]['"
|
||||
endif
|
||||
|
||||
" NOTE the double escaping \\|
|
||||
nnoremap <buffer> <silent> [[ :call <SID>VbSearch('^\s*\(\(private\|public\)\s\+\)\=\(function\\|sub\)', 'bW')<cr>
|
||||
nnoremap <buffer> <silent> ]] :call <SID>VbSearch('^\s*\(\(private\|public\)\s\+\)\=\(function\\|sub\)', 'W')<cr>
|
||||
nnoremap <buffer> <silent> [] :call <SID>VbSearch('^\s*\<end\>\s\+\(function\\|sub\)', 'bW')<cr>
|
||||
nnoremap <buffer> <silent> ][ :call <SID>VbSearch('^\s*\<end\>\s\+\(function\\|sub\)', 'W')<cr>
|
||||
" TODO: line start anchors are almost certainly overly restrictive - allow
|
||||
" after statement separators. Even in QuickBasic only block IF statements
|
||||
" were required to be at the start of a line.
|
||||
if exists("loaded_matchit") && !exists("b:match_words")
|
||||
let b:match_ignorecase = 1
|
||||
let b:match_words =
|
||||
\ '\%(^\s*\)\@<=\<if\>.*\<then\>\s*\%($\|''\):\%(^\s*\)\@<=\<else\>:\%(^\s*\)\@<=\<elseif\>:\%(^\s*\)\@<=\<end\>\s\+\<if\>,' .
|
||||
\ '\%(^\s*\)\@<=\<for\>:\%(^\s*\)\@<=\<next\>,' .
|
||||
\ '\%(^\s*\)\@<=\<while\>:\%(^\s*\)\@<=\<wend\>,' .
|
||||
\ '\%(^\s*\)\@<=\<do\>:\%(^\s*\)\@<=\<loop\>\s\+\<while\>,' .
|
||||
\ '\%(^\s*\)\@<=\<select\>\s\+\<case\>:\%(^\s*\)\@<=\<case\>:\%(^\s*\)\@<=\<end\>\s\+\<select\>,' .
|
||||
\ '\%(^\s*\)\@<=\<enum\>:\%(^\s*\)\@<=\<end\>\s\<enum\>,' .
|
||||
\ '\%(^\s*\)\@<=\<with\>:\%(^\s*\)\@<=\<end\>\s\<with\>,' .
|
||||
\ '\%(^\s*\)\@<=\%(\<\%(private\|public\)\>\s\+\)\=\<function\>\s\+\([^ \t(]\+\):\%(^\s*\)\@<=\<\1\>\s*=:\%(^\s*\)\@<=\<end\>\s\+\<function\>,' .
|
||||
\ '\%(^\s*\)\@<=\%(\<\%(private\|public\)\>\s\+\)\=\<sub\>\s\+:\%(^\s*\)\@<=\<end\>\s\+\<sub\>'
|
||||
let b:undo_ftplugin .= " | unlet! b:match_words b:match_ignorecase"
|
||||
endif
|
||||
|
||||
" matchit support
|
||||
if exists("loaded_matchit")
|
||||
let b:match_ignorecase=1
|
||||
let b:match_words=
|
||||
\ '\%(^\s*\)\@<=\<if\>.*\<then\>\s*$:\%(^\s*\)\@<=\<else\>:\%(^\s*\)\@<=\<elseif\>:\%(^\s*\)\@<=\<end\>\s\+\<if\>,' .
|
||||
\ '\%(^\s*\)\@<=\<for\>:\%(^\s*\)\@<=\<next\>,' .
|
||||
\ '\%(^\s*\)\@<=\<while\>:\%(^\s*\)\@<=\<wend\>,' .
|
||||
\ '\%(^\s*\)\@<=\<do\>:\%(^\s*\)\@<=\<loop\>\s\+\<while\>,' .
|
||||
\ '\%(^\s*\)\@<=\<select\>\s\+\<case\>:\%(^\s*\)\@<=\<case\>:\%(^\s*\)\@<=\<end\>\s\+\<select\>,' .
|
||||
\ '\%(^\s*\)\@<=\<enum\>:\%(^\s*\)\@<=\<end\>\s\<enum\>,' .
|
||||
\ '\%(^\s*\)\@<=\<with\>:\%(^\s*\)\@<=\<end\>\s\<with\>,' .
|
||||
\ '\%(^\s*\)\@<=\%(\<\%(private\|public\)\>\s\+\)\=\<function\>\s\+\([^ \t(]\+\):\%(^\s*\)\@<=\<\1\>\s*=:\%(^\s*\)\@<=\<end\>\s\+\<function\>,' .
|
||||
\ '\%(^\s*\)\@<=\%(\<\%(private\|public\)\>\s\+\)\=\<sub\>\s\+:\%(^\s*\)\@<=\<end\>\s\+\<sub\>'
|
||||
if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
|
||||
let b:browsefilter = "Visual Basic Source Files (*.bas)\t*.bas\n" .
|
||||
\ "Visual Basic Form Files (*.frm)\t*.frm\n" .
|
||||
\ "All Files (*.*)\t*.*\n"
|
||||
let b:undo_ftplugin .= " | unlet! b:browsefilter"
|
||||
endif
|
||||
|
||||
let &cpo = s:cpo_save
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Zimbu
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2017 Dec 05
|
||||
" Last Change: 2021 Nov 12
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -34,9 +34,11 @@ setlocal errorformat^=%f\ line\ %l\ col\ %c:\ %m,ERROR:\ %m
|
||||
|
||||
" When the matchit plugin is loaded, this makes the % command skip parens and
|
||||
" braces in comments.
|
||||
let b:match_words = '\(^\s*\)\@<=\(MODULE\|CLASS\|INTERFACE\|BITS\|ENUM\|SHARED\|FUNC\|REPLACE\|DEFINE\|PROC\|EQUAL\|MAIN\|IF\|GENERATE_IF\|WHILE\|REPEAT\|WITH\|DO\|FOR\|SWITCH\|TRY\)\>\|{\s*$:\(^\s*\)\@<=\(ELSE\|ELSEIF\|GENERATE_ELSE\|GENERATE_ELSEIF\|CATCH\|FINALLY\)\>:\(^\s*\)\@<=\(}\|\<UNTIL\>\)'
|
||||
|
||||
let b:match_skip = 's:comment\|string\|zimbuchar'
|
||||
if exists("loaded_matchit") && !exists("b:match_words")
|
||||
let b:match_words = '\(^\s*\)\@<=\(MODULE\|CLASS\|INTERFACE\|BITS\|ENUM\|SHARED\|FUNC\|REPLACE\|DEFINE\|PROC\|EQUAL\|MAIN\|IF\|GENERATE_IF\|WHILE\|REPEAT\|WITH\|DO\|FOR\|SWITCH\|TRY\)\>\|{\s*$:\(^\s*\)\@<=\(ELSE\|ELSEIF\|GENERATE_ELSE\|GENERATE_ELSEIF\|CATCH\|FINALLY\)\>:\(^\s*\)\@<=\(}\|\<UNTIL\>\)'
|
||||
let b:match_skip = 's:comment\|string\|zimbuchar'
|
||||
let b:undo_ftplugin ..= " | unlet! b:match_words b:match_skip"
|
||||
endif
|
||||
|
||||
setlocal tw=78
|
||||
setlocal et sts=2 sw=2
|
||||
@@ -135,9 +137,60 @@ iabbr <buffer> <expr> until GCUpperSpace("until")
|
||||
iabbr <buffer> <expr> while GCUpperSpace("while")
|
||||
iabbr <buffer> <expr> repeat GCUpper("repeat")
|
||||
|
||||
let b:undo_ftplugin ..=
|
||||
\ " | iunabbr <buffer> alias" ..
|
||||
\ " | iunabbr <buffer> arg" ..
|
||||
\ " | iunabbr <buffer> break" ..
|
||||
\ " | iunabbr <buffer> case" ..
|
||||
\ " | iunabbr <buffer> catch" ..
|
||||
\ " | iunabbr <buffer> check" ..
|
||||
\ " | iunabbr <buffer> class" ..
|
||||
\ " | iunabbr <buffer> interface" ..
|
||||
\ " | iunabbr <buffer> implements" ..
|
||||
\ " | iunabbr <buffer> shared" ..
|
||||
\ " | iunabbr <buffer> continue" ..
|
||||
\ " | iunabbr <buffer> default" ..
|
||||
\ " | iunabbr <buffer> extends" ..
|
||||
\ " | iunabbr <buffer> do" ..
|
||||
\ " | iunabbr <buffer> else" ..
|
||||
\ " | iunabbr <buffer> elseif" ..
|
||||
\ " | iunabbr <buffer> enum" ..
|
||||
\ " | iunabbr <buffer> exit" ..
|
||||
\ " | iunabbr <buffer> false" ..
|
||||
\ " | iunabbr <buffer> fail" ..
|
||||
\ " | iunabbr <buffer> finally" ..
|
||||
\ " | iunabbr <buffer> for" ..
|
||||
\ " | iunabbr <buffer> func" ..
|
||||
\ " | iunabbr <buffer> if" ..
|
||||
\ " | iunabbr <buffer> import" ..
|
||||
\ " | iunabbr <buffer> in" ..
|
||||
\ " | iunabbr <buffer> io" ..
|
||||
\ " | iunabbr <buffer> main" ..
|
||||
\ " | iunabbr <buffer> module" ..
|
||||
\ " | iunabbr <buffer> new" ..
|
||||
\ " | iunabbr <buffer> nil" ..
|
||||
\ " | iunabbr <buffer> ok" ..
|
||||
\ " | iunabbr <buffer> proc" ..
|
||||
\ " | iunabbr <buffer> proceed" ..
|
||||
\ " | iunabbr <buffer> return" ..
|
||||
\ " | iunabbr <buffer> step" ..
|
||||
\ " | iunabbr <buffer> switch" ..
|
||||
\ " | iunabbr <buffer> sys" ..
|
||||
\ " | iunabbr <buffer> this" ..
|
||||
\ " | iunabbr <buffer> throw" ..
|
||||
\ " | iunabbr <buffer> try" ..
|
||||
\ " | iunabbr <buffer> to" ..
|
||||
\ " | iunabbr <buffer> true" ..
|
||||
\ " | iunabbr <buffer> until" ..
|
||||
\ " | iunabbr <buffer> while" ..
|
||||
\ " | iunabbr <buffer> repeat"
|
||||
|
||||
if !exists("no_plugin_maps") && !exists("no_zimbu_maps")
|
||||
nnoremap <silent> <buffer> [[ m`:call ZimbuGoStartBlock()<CR>
|
||||
nnoremap <silent> <buffer> ]] m`:call ZimbuGoEndBlock()<CR>
|
||||
let b:undo_ftplugin ..=
|
||||
\ " | silent! exe 'nunmap <buffer> [['" ..
|
||||
\ " | silent! exe 'nunmap <buffer> ]]'"
|
||||
endif
|
||||
|
||||
" Using a function makes sure the search pattern is restored
|
||||
|
||||
@@ -18,13 +18,13 @@ setlocal comments=:# commentstring=#\ %s formatoptions-=t formatoptions+=croql
|
||||
|
||||
let b:undo_ftplugin = "setl com< cms< fo< "
|
||||
|
||||
if executable('zsh')
|
||||
if executable('zsh') && &shell !~# '/\%(nologin\|false\)$'
|
||||
if !has('gui_running') && executable('less')
|
||||
command! -buffer -nargs=1 RunHelp silent exe '!MANPAGER= zsh -ic "autoload -Uz run-help; run-help <args> 2>/dev/null | LESS= less"' | redraw!
|
||||
command! -buffer -nargs=1 RunHelp silent exe '!MANPAGER= zsh -c "autoload -Uz run-help; run-help <args> 2>/dev/null | LESS= less"' | redraw!
|
||||
elseif has('terminal')
|
||||
command! -buffer -nargs=1 RunHelp silent exe ':term zsh -ic "autoload -Uz run-help; run-help <args>"'
|
||||
command! -buffer -nargs=1 RunHelp silent exe ':term zsh -c "autoload -Uz run-help; run-help <args>"'
|
||||
else
|
||||
command! -buffer -nargs=1 RunHelp echo system('zsh -ic "autoload -Uz run-help; run-help <args> 2>/dev/null"')
|
||||
command! -buffer -nargs=1 RunHelp echo system('zsh -c "autoload -Uz run-help; run-help <args> 2>/dev/null"')
|
||||
endif
|
||||
if !exists('current_compiler')
|
||||
compiler zsh
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
" Vim indent file
|
||||
" Language: Clojure
|
||||
" Maintainer: Alex Vear <av@axvr.io>
|
||||
" Maintainer: Alex Vear <alex@vear.uk>
|
||||
" Former Maintainers: Sung Pae <self@sungpae.com>
|
||||
" Meikel Brandmeyer <mb@kotka.de>
|
||||
" URL: https://github.com/clojure-vim/clojure.vim
|
||||
" License: Vim (see :h license)
|
||||
" Last Change: 2021-02-13
|
||||
" Last Change: 2021-10-26
|
||||
|
||||
if exists("b:did_indent")
|
||||
finish
|
||||
@@ -24,7 +24,7 @@ setlocal indentkeys=!,o,O
|
||||
if exists("*searchpairpos")
|
||||
|
||||
if !exists('g:clojure_maxlines')
|
||||
let g:clojure_maxlines = 100
|
||||
let g:clojure_maxlines = 300
|
||||
endif
|
||||
|
||||
if !exists('g:clojure_fuzzy_indent')
|
||||
@@ -71,14 +71,10 @@ if exists("*searchpairpos")
|
||||
return s:current_char() =~# '\v[\(\)\[\]\{\}]' && !s:ignored_region()
|
||||
endfunction
|
||||
|
||||
" Returns 1 if string matches a pattern in 'patterns', which may be a
|
||||
" list of patterns, or a comma-delimited string of implicitly anchored
|
||||
" patterns.
|
||||
" Returns 1 if string matches a pattern in 'patterns', which should be
|
||||
" a list of patterns.
|
||||
function! s:match_one(patterns, string)
|
||||
let list = type(a:patterns) == type([])
|
||||
\ ? a:patterns
|
||||
\ : map(split(a:patterns, ','), '"^" . v:val . "$"')
|
||||
for pat in list
|
||||
for pat in a:patterns
|
||||
if a:string =~# pat | return 1 | endif
|
||||
endfor
|
||||
endfunction
|
||||
@@ -215,9 +211,10 @@ if exists("*searchpairpos")
|
||||
endfunction
|
||||
|
||||
" Check if form is a reader conditional, that is, it is prefixed by #?
|
||||
" or @#?
|
||||
" or #?@
|
||||
function! s:is_reader_conditional_special_case(position)
|
||||
return getline(a:position[0])[a:position[1] - 3 : a:position[1] - 2] == "#?"
|
||||
\|| getline(a:position[0])[a:position[1] - 4 : a:position[1] - 2] == "#?@"
|
||||
endfunction
|
||||
|
||||
" Returns 1 for opening brackets, -1 for _anything else_.
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
" Language: MSDOS batch file (with NT command extensions)
|
||||
" Maintainer: Ken Takata
|
||||
" URL: https://github.com/k-takata/vim-dosbatch-indent
|
||||
" Last Change: 2017 May 10
|
||||
" Last Change: 2021-10-18
|
||||
" Filenames: *.bat
|
||||
" License: VIM License
|
||||
|
||||
@@ -17,6 +17,8 @@ setlocal indentexpr=GetDosBatchIndent(v:lnum)
|
||||
setlocal indentkeys=!^F,o,O
|
||||
setlocal indentkeys+=0=)
|
||||
|
||||
let b:undo_indent = "setl ai< inde< indk< si<"
|
||||
|
||||
if exists("*GetDosBatchIndent")
|
||||
finish
|
||||
endif
|
||||
|
||||
@@ -20,6 +20,8 @@ setlocal autoindent " indentexpr isn't much help otherwise
|
||||
setlocal indentexpr=GetMesonIndent(v:lnum)
|
||||
setlocal indentkeys+==elif,=else,=endforeach,=endif,0)
|
||||
|
||||
let b:undo_indent = "setl ai< inde< indk< lisp<"
|
||||
|
||||
" Only define the function once.
|
||||
if exists("*GetMesonIndent")
|
||||
finish
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
" Language: NSIS script
|
||||
" Maintainer: Ken Takata
|
||||
" URL: https://github.com/k-takata/vim-nsis
|
||||
" Last Change: 2018-01-21
|
||||
" Last Change: 2021-10-18
|
||||
" Filenames: *.nsi
|
||||
" License: VIM License
|
||||
|
||||
@@ -17,6 +17,8 @@ setlocal indentexpr=GetNsisIndent(v:lnum)
|
||||
setlocal indentkeys=!^F,o,O
|
||||
setlocal indentkeys+==~${Else,=~${EndIf,=~${EndUnless,=~${AndIf,=~${AndUnless,=~${OrIf,=~${OrUnless,=~${Case,=~${Default,=~${EndSelect,=~${EndSwith,=~${Loop,=~${Next,=~${MementoSectionEnd,=~FunctionEnd,=~SectionEnd,=~SectionGroupEnd,=~PageExEnd,0=~!macroend,0=~!if,0=~!else,0=~!endif
|
||||
|
||||
let b:undo_indent = "setl ai< inde< indk< si<"
|
||||
|
||||
if exists("*GetNsisIndent")
|
||||
finish
|
||||
endif
|
||||
|
||||
@@ -109,7 +109,7 @@ function! GetShIndent()
|
||||
let ind += s:indent_value('continuation-line')
|
||||
endif
|
||||
elseif s:end_block(line) && !s:start_block(line)
|
||||
let ind -= s:indent_value('default')
|
||||
let ind = indent(lnum)
|
||||
elseif pnum != 0 &&
|
||||
\ s:is_continuation_line(pline) &&
|
||||
\ !s:end_block(curline) &&
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
" Based on Tera Term Version 4.100
|
||||
" Maintainer: Ken Takata
|
||||
" URL: https://github.com/k-takata/vim-teraterm
|
||||
" Last Change: 2018-08-31
|
||||
" Last Change: 2021-10-18
|
||||
" Filenames: *.ttl
|
||||
" License: VIM License
|
||||
|
||||
@@ -18,6 +18,8 @@ setlocal indentexpr=GetTeraTermIndent(v:lnum)
|
||||
setlocal indentkeys=!^F,o,O,e
|
||||
setlocal indentkeys+==elseif,=endif,=loop,=next,=enduntil,=endwhile
|
||||
|
||||
let b:undo_indent = "setl ai< inde< indk< si<"
|
||||
|
||||
if exists("*GetTeraTermIndent")
|
||||
finish
|
||||
endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim indent file
|
||||
" Language: Vim script
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2021 Apr 18
|
||||
" Last Change: 2021 Nov 27
|
||||
|
||||
" Only load this indent file when no other was loaded.
|
||||
if exists("b:did_indent")
|
||||
@@ -12,6 +12,7 @@ let b:did_indent = 1
|
||||
setlocal indentexpr=GetVimIndent()
|
||||
setlocal indentkeys+==end,=},=else,=cat,=finall,=END,0\\,0=\"\\\
|
||||
setlocal indentkeys-=0#
|
||||
setlocal indentkeys-=:
|
||||
|
||||
let b:undo_indent = "setl indentkeys< indentexpr<"
|
||||
|
||||
@@ -107,7 +108,7 @@ function GetVimIndentIntern()
|
||||
if i >= 0
|
||||
let ind += shiftwidth()
|
||||
if strpart(prev_text, i, 1) == '|' && has('syntax_items')
|
||||
\ && synIDattr(synID(lnum, i, 1), "name") =~ '\(Comment\|String\)$'
|
||||
\ && synIDattr(synID(lnum, i, 1), "name") =~ '\(Comment\|String\|PatSep\)$'
|
||||
let ind -= shiftwidth()
|
||||
endif
|
||||
endif
|
||||
|
||||
@@ -39,6 +39,8 @@ setlocal indentkeys=o,O,*<Return>,<>>,<<>,/,{,},!^F
|
||||
" autoindent: used when the indentexpr returns -1
|
||||
setlocal autoindent
|
||||
|
||||
let b:undo_indent = "setl ai< inde< indk<"
|
||||
|
||||
if !exists('b:xml_indent_open')
|
||||
let b:xml_indent_open = '.\{-}<[:A-Z_a-z]'
|
||||
" pre tag, e.g. <address>
|
||||
@@ -51,6 +53,10 @@ if !exists('b:xml_indent_close')
|
||||
" let b:xml_indent_close = '.\{-}</\(address\)\@!'
|
||||
endif
|
||||
|
||||
if !exists('b:xml_indent_continuation_filetype')
|
||||
let b:xml_indent_continuation_filetype = 'xml'
|
||||
endif
|
||||
|
||||
let &cpo = s:keepcpo
|
||||
unlet s:keepcpo
|
||||
|
||||
@@ -162,7 +168,7 @@ endfun
|
||||
|
||||
func! <SID>IsXMLContinuation(line)
|
||||
" Checks, whether or not the line matches a start-of-tag
|
||||
return a:line !~ '^\s*<' && &ft is# 'xml'
|
||||
return a:line !~ '^\s*<' && &ft =~# b:xml_indent_continuation_filetype
|
||||
endfunc
|
||||
|
||||
func! <SID>HasNoTagEnd(line)
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
" You can also use this as a start for your own set of menus.
|
||||
"
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2020 Sep 28
|
||||
" Last Change: 2021 Dec 22
|
||||
|
||||
" Note that ":an" (short for ":anoremenu") is often used to make a menu work
|
||||
" in all modes and avoid side effects from mappings defined by the user.
|
||||
@@ -717,6 +717,11 @@ func s:BMCanAdd(name, num)
|
||||
return 0
|
||||
endif
|
||||
|
||||
" no name with control characters
|
||||
if a:name =~ '[\x01-\x1f]'
|
||||
return 0
|
||||
endif
|
||||
|
||||
" no special buffer, such as terminal or popup
|
||||
let buftype = getbufvar(a:num, '&buftype')
|
||||
if buftype != '' && buftype != 'nofile' && buftype != 'nowrite'
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" These commands create the option window.
|
||||
"
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2020 Oct 27
|
||||
" Last Change: 2021 Dec 21
|
||||
|
||||
" If there already is an option window, jump to that one.
|
||||
let buf = bufnr('option-window')
|
||||
@@ -260,6 +260,8 @@ call <SID>OptionG("sect", §)
|
||||
call <SID>AddOption("path", gettext("list of directory names used for file searching"))
|
||||
call append("$", "\t" .. s:global_or_local)
|
||||
call <SID>OptionG("pa", &pa)
|
||||
call <SID>AddOption("cdhome", gettext(":cd without argument goes to the home directory"))
|
||||
call <SID>BinOptionG("cdh", &cdh)
|
||||
call <SID>AddOption("cdpath", gettext("list of directory names used for :cd"))
|
||||
call <SID>OptionG("cd", &cd)
|
||||
if exists("+autochdir")
|
||||
@@ -560,14 +562,22 @@ endif
|
||||
call <SID>Header(gettext("terminal"))
|
||||
call <SID>AddOption("term", gettext("name of the used terminal"))
|
||||
call <SID>OptionG("term", &term)
|
||||
|
||||
call <SID>AddOption("ttytype", gettext("alias for 'term'"))
|
||||
call <SID>OptionG("tty", &tty)
|
||||
|
||||
call <SID>AddOption("ttybuiltin", gettext("check built-in termcaps first"))
|
||||
call <SID>BinOptionG("tbi", &tbi)
|
||||
|
||||
call <SID>AddOption("ttyfast", gettext("terminal connection is fast"))
|
||||
call <SID>BinOptionG("tf", &tf)
|
||||
|
||||
call <SID>AddOption("xtermcodes", gettext("request terminal key codes when an xterm is detected"))
|
||||
call <SID>BinOptionG("xtermcodes", &xtermcodes)
|
||||
|
||||
call <SID>AddOption("weirdinvert", gettext("terminal that requires extra redrawing"))
|
||||
call <SID>BinOptionG("wiv", &wiv)
|
||||
|
||||
call <SID>AddOption("esckeys", gettext("recognize keys that start with <Esc> in Insert mode"))
|
||||
call <SID>BinOptionG("ek", &ek)
|
||||
call <SID>AddOption("scrolljump", gettext("minimal number of lines to scroll at a time"))
|
||||
@@ -652,6 +662,8 @@ if has("gui")
|
||||
endif
|
||||
call <SID>AddOption("guiheadroom", gettext("room (in pixels) left above/below the window"))
|
||||
call append("$", " \tset ghr=" . &ghr)
|
||||
call <SID>AddOption("guiligatures", gettext("list of ASCII characters that can be combined into complex shapes"))
|
||||
call <SID>OptionG("gli", &gli)
|
||||
endif
|
||||
if has("directx")
|
||||
call <SID>AddOption("renderoptions", gettext("options for text rendering"))
|
||||
@@ -840,6 +852,9 @@ if has("insert_expand")
|
||||
call <SID>AddOption("thesaurus", gettext("list of thesaurus files for keyword completion"))
|
||||
call append("$", "\t" .. s:global_or_local)
|
||||
call <SID>OptionG("tsr", &tsr)
|
||||
call <SID>AddOption("thesaurusfunc", gettext("function used for thesaurus completion"))
|
||||
call append("$", "\t" .. s:global_or_local)
|
||||
call <SID>OptionG("tsrfu", &tsrfu)
|
||||
endif
|
||||
call <SID>AddOption("infercase", gettext("adjust case of a keyword completion match"))
|
||||
call append("$", "\t" .. s:local_to_buffer)
|
||||
|
||||
251
runtime/pack/dist/opt/matchit/autoload/matchit.vim
vendored
251
runtime/pack/dist/opt/matchit/autoload/matchit.vim
vendored
@@ -1,6 +1,11 @@
|
||||
" matchit.vim: (global plugin) Extended "%" matching
|
||||
" autload script of matchit plugin, see ../plugin/matchit.vim
|
||||
" Last Change: Mar 01, 2020
|
||||
" Last Change: Jun 10, 2021
|
||||
|
||||
" Neovim does not support scriptversion
|
||||
if has("vimscript-4")
|
||||
scriptversion 4
|
||||
endif
|
||||
|
||||
let s:last_mps = ""
|
||||
let s:last_words = ":"
|
||||
@@ -30,11 +35,11 @@ function s:RestoreOptions()
|
||||
" In s:CleanUp(), :execute "set" restore_options .
|
||||
let restore_options = ""
|
||||
if get(b:, 'match_ignorecase', &ic) != &ic
|
||||
let restore_options .= (&ic ? " " : " no") . "ignorecase"
|
||||
let restore_options ..= (&ic ? " " : " no") .. "ignorecase"
|
||||
let &ignorecase = b:match_ignorecase
|
||||
endif
|
||||
if &ve != ''
|
||||
let restore_options = " ve=" . &ve . restore_options
|
||||
let restore_options = " ve=" .. &ve .. restore_options
|
||||
set ve=
|
||||
endif
|
||||
return restore_options
|
||||
@@ -42,22 +47,23 @@ endfunction
|
||||
|
||||
function matchit#Match_wrapper(word, forward, mode) range
|
||||
let restore_options = s:RestoreOptions()
|
||||
" If this function was called from Visual mode, make sure that the cursor
|
||||
" is at the correct end of the Visual range:
|
||||
if a:mode == "v"
|
||||
execute "normal! gv\<Esc>"
|
||||
elseif a:mode == "o" && mode(1) !~# '[vV]'
|
||||
exe "norm! v"
|
||||
elseif a:mode == "n" && mode(1) =~# 'ni'
|
||||
exe "norm! v"
|
||||
endif
|
||||
" In s:CleanUp(), we may need to check whether the cursor moved forward.
|
||||
let startpos = [line("."), col(".")]
|
||||
" Use default behavior if called with a count.
|
||||
" if a count has been applied, use the default [count]% mode (see :h N%)
|
||||
if v:count
|
||||
exe "normal! " . v:count . "%"
|
||||
exe "normal! " .. v:count .. "%"
|
||||
return s:CleanUp(restore_options, a:mode, startpos)
|
||||
end
|
||||
if a:mode =~# "v" && mode(1) =~# 'ni'
|
||||
exe "norm! gv"
|
||||
elseif a:mode == "o" && mode(1) !~# '[vV]'
|
||||
exe "norm! v"
|
||||
" If this function was called from Visual mode, make sure that the cursor
|
||||
" is at the correct end of the Visual range:
|
||||
elseif a:mode == "v"
|
||||
execute "normal! gv\<Esc>"
|
||||
let startpos = [line("."), col(".")]
|
||||
endif
|
||||
|
||||
" First step: if not already done, set the script variables
|
||||
" s:do_BR flag for whether there are backrefs
|
||||
@@ -78,30 +84,30 @@ function matchit#Match_wrapper(word, forward, mode) range
|
||||
" quote the special chars in 'matchpairs', replace [,:] with \| and then
|
||||
" append the builtin pairs (/*, */, #if, #ifdef, #ifndef, #else, #elif,
|
||||
" #endif)
|
||||
let default = escape(&mps, '[$^.*~\\/?]') . (strlen(&mps) ? "," : "") .
|
||||
let default = escape(&mps, '[$^.*~\\/?]') .. (strlen(&mps) ? "," : "") ..
|
||||
\ '\/\*:\*\/,#\s*if\%(n\=def\)\=:#\s*else\>:#\s*elif\>:#\s*endif\>'
|
||||
" s:all = pattern with all the keywords
|
||||
let match_words = match_words . (strlen(match_words) ? "," : "") . default
|
||||
let match_words = match_words .. (strlen(match_words) ? "," : "") .. default
|
||||
let s:last_words = match_words
|
||||
if match_words !~ s:notslash . '\\\d'
|
||||
if match_words !~ s:notslash .. '\\\d'
|
||||
let s:do_BR = 0
|
||||
let s:pat = match_words
|
||||
else
|
||||
let s:do_BR = 1
|
||||
let s:pat = s:ParseWords(match_words)
|
||||
endif
|
||||
let s:all = substitute(s:pat, s:notslash . '\zs[,:]\+', '\\|', 'g')
|
||||
let s:all = substitute(s:pat, s:notslash .. '\zs[,:]\+', '\\|', 'g')
|
||||
" Just in case there are too many '\(...)' groups inside the pattern, make
|
||||
" sure to use \%(...) groups, so that error E872 can be avoided
|
||||
let s:all = substitute(s:all, '\\(', '\\%(', 'g')
|
||||
let s:all = '\%(' . s:all . '\)'
|
||||
let s:all = '\%(' .. s:all .. '\)'
|
||||
if exists("b:match_debug")
|
||||
let b:match_pat = s:pat
|
||||
endif
|
||||
" Reconstruct the version with unresolved backrefs.
|
||||
let s:patBR = substitute(match_words.',',
|
||||
\ s:notslash.'\zs[,:]*,[,:]*', ',', 'g')
|
||||
let s:patBR = substitute(s:patBR, s:notslash.'\zs:\{2,}', ':', 'g')
|
||||
let s:patBR = substitute(match_words .. ',',
|
||||
\ s:notslash .. '\zs[,:]*,[,:]*', ',', 'g')
|
||||
let s:patBR = substitute(s:patBR, s:notslash .. '\zs:\{2,}', ':', 'g')
|
||||
endif
|
||||
|
||||
" Second step: set the following local variables:
|
||||
@@ -128,12 +134,15 @@ function matchit#Match_wrapper(word, forward, mode) range
|
||||
let curcol = match(matchline, regexp)
|
||||
" If there is no match, give up.
|
||||
if curcol == -1
|
||||
" Make sure macros abort properly
|
||||
"exe "norm! \<esc>"
|
||||
call feedkeys("\e", 'tni')
|
||||
return s:CleanUp(restore_options, a:mode, startpos)
|
||||
endif
|
||||
let endcol = matchend(matchline, regexp)
|
||||
let suf = strlen(matchline) - endcol
|
||||
let prefix = (curcol ? '^.*\%' . (curcol + 1) . 'c\%(' : '^\%(')
|
||||
let suffix = (suf ? '\)\%' . (endcol + 1) . 'c.*$' : '\)$')
|
||||
let prefix = (curcol ? '^.*\%' .. (curcol + 1) .. 'c\%(' : '^\%(')
|
||||
let suffix = (suf ? '\)\%' .. (endcol + 1) .. 'c.*$' : '\)$')
|
||||
endif
|
||||
if exists("b:match_debug")
|
||||
let b:match_match = matchstr(matchline, regexp)
|
||||
@@ -150,7 +159,7 @@ function matchit#Match_wrapper(word, forward, mode) range
|
||||
" 'while:endwhile' or whatever. A bit of a kluge: s:Choose() returns
|
||||
" group . "," . groupBR, and we pick it apart.
|
||||
let group = s:Choose(s:pat, matchline, ",", ":", prefix, suffix, s:patBR)
|
||||
let i = matchend(group, s:notslash . ",")
|
||||
let i = matchend(group, s:notslash .. ",")
|
||||
let groupBR = strpart(group, i)
|
||||
let group = strpart(group, 0, i-1)
|
||||
" Now, matchline =~ prefix . substitute(group,':','\|','g') . suffix
|
||||
@@ -159,32 +168,32 @@ function matchit#Match_wrapper(word, forward, mode) range
|
||||
endif
|
||||
if exists("b:match_debug")
|
||||
let b:match_wholeBR = groupBR
|
||||
let i = matchend(groupBR, s:notslash . ":")
|
||||
let i = matchend(groupBR, s:notslash .. ":")
|
||||
let b:match_iniBR = strpart(groupBR, 0, i-1)
|
||||
endif
|
||||
|
||||
" Fourth step: Set the arguments for searchpair().
|
||||
let i = matchend(group, s:notslash . ":")
|
||||
let j = matchend(group, '.*' . s:notslash . ":")
|
||||
let i = matchend(group, s:notslash .. ":")
|
||||
let j = matchend(group, '.*' .. s:notslash .. ":")
|
||||
let ini = strpart(group, 0, i-1)
|
||||
let mid = substitute(strpart(group, i,j-i-1), s:notslash.'\zs:', '\\|', 'g')
|
||||
let mid = substitute(strpart(group, i,j-i-1), s:notslash .. '\zs:', '\\|', 'g')
|
||||
let fin = strpart(group, j)
|
||||
"Un-escape the remaining , and : characters.
|
||||
let ini = substitute(ini, s:notslash . '\zs\\\(:\|,\)', '\1', 'g')
|
||||
let mid = substitute(mid, s:notslash . '\zs\\\(:\|,\)', '\1', 'g')
|
||||
let fin = substitute(fin, s:notslash . '\zs\\\(:\|,\)', '\1', 'g')
|
||||
let ini = substitute(ini, s:notslash .. '\zs\\\(:\|,\)', '\1', 'g')
|
||||
let mid = substitute(mid, s:notslash .. '\zs\\\(:\|,\)', '\1', 'g')
|
||||
let fin = substitute(fin, s:notslash .. '\zs\\\(:\|,\)', '\1', 'g')
|
||||
" searchpair() requires that these patterns avoid \(\) groups.
|
||||
let ini = substitute(ini, s:notslash . '\zs\\(', '\\%(', 'g')
|
||||
let mid = substitute(mid, s:notslash . '\zs\\(', '\\%(', 'g')
|
||||
let fin = substitute(fin, s:notslash . '\zs\\(', '\\%(', 'g')
|
||||
let ini = substitute(ini, s:notslash .. '\zs\\(', '\\%(', 'g')
|
||||
let mid = substitute(mid, s:notslash .. '\zs\\(', '\\%(', 'g')
|
||||
let fin = substitute(fin, s:notslash .. '\zs\\(', '\\%(', 'g')
|
||||
" Set mid. This is optimized for readability, not micro-efficiency!
|
||||
if a:forward && matchline =~ prefix . fin . suffix
|
||||
\ || !a:forward && matchline =~ prefix . ini . suffix
|
||||
if a:forward && matchline =~ prefix .. fin .. suffix
|
||||
\ || !a:forward && matchline =~ prefix .. ini .. suffix
|
||||
let mid = ""
|
||||
endif
|
||||
" Set flag. This is optimized for readability, not micro-efficiency!
|
||||
if a:forward && matchline =~ prefix . fin . suffix
|
||||
\ || !a:forward && matchline !~ prefix . ini . suffix
|
||||
if a:forward && matchline =~ prefix .. fin .. suffix
|
||||
\ || !a:forward && matchline !~ prefix .. ini .. suffix
|
||||
let flag = "bW"
|
||||
else
|
||||
let flag = "W"
|
||||
@@ -193,14 +202,14 @@ function matchit#Match_wrapper(word, forward, mode) range
|
||||
if exists("b:match_skip")
|
||||
let skip = b:match_skip
|
||||
elseif exists("b:match_comment") " backwards compatibility and testing!
|
||||
let skip = "r:" . b:match_comment
|
||||
let skip = "r:" .. b:match_comment
|
||||
else
|
||||
let skip = 's:comment\|string'
|
||||
endif
|
||||
let skip = s:ParseSkip(skip)
|
||||
if exists("b:match_debug")
|
||||
let b:match_ini = ini
|
||||
let b:match_tail = (strlen(mid) ? mid.'\|' : '') . fin
|
||||
let b:match_tail = (strlen(mid) ? mid .. '\|' : '') .. fin
|
||||
endif
|
||||
|
||||
" Fifth step: actually start moving the cursor and call searchpair().
|
||||
@@ -210,25 +219,29 @@ function matchit#Match_wrapper(word, forward, mode) range
|
||||
if skip =~ 'synID' && !(has("syntax") && exists("g:syntax_on"))
|
||||
let skip = "0"
|
||||
else
|
||||
execute "if " . skip . "| let skip = '0' | endif"
|
||||
execute "if " .. skip .. "| let skip = '0' | endif"
|
||||
endif
|
||||
let sp_return = searchpair(ini, mid, fin, flag, skip)
|
||||
if &selection isnot# 'inclusive' && a:mode == 'v'
|
||||
" move cursor one pos to the right, because selection is not inclusive
|
||||
" add virtualedit=onemore, to make it work even when the match ends the " line
|
||||
" add virtualedit=onemore, to make it work even when the match ends the
|
||||
" line
|
||||
if !(col('.') < col('$')-1)
|
||||
set ve=onemore
|
||||
let eolmark=1 " flag to set a mark on eol (since we cannot move there)
|
||||
endif
|
||||
norm! l
|
||||
endif
|
||||
let final_position = "call cursor(" . line(".") . "," . col(".") . ")"
|
||||
let final_position = "call cursor(" .. line(".") .. "," .. col(".") .. ")"
|
||||
" Restore cursor position and original screen.
|
||||
call winrestview(view)
|
||||
normal! m'
|
||||
if sp_return > 0
|
||||
execute final_position
|
||||
endif
|
||||
return s:CleanUp(restore_options, a:mode, startpos, mid.'\|'.fin)
|
||||
if exists('eolmark') && eolmark
|
||||
call setpos("''", [0, line('.'), col('$'), 0]) " set mark on the eol
|
||||
endif
|
||||
return s:CleanUp(restore_options, a:mode, startpos, mid .. '\|' .. fin)
|
||||
endfun
|
||||
|
||||
" Restore options and do some special handling for Operator-pending mode.
|
||||
@@ -270,16 +283,16 @@ endfun
|
||||
" a:matchline = "123<tag>12" or "123</tag>12"
|
||||
" then extract "tag" from a:matchline and return "<tag>:</tag>" .
|
||||
fun! s:InsertRefs(groupBR, prefix, group, suffix, matchline)
|
||||
if a:matchline !~ a:prefix .
|
||||
\ substitute(a:group, s:notslash . '\zs:', '\\|', 'g') . a:suffix
|
||||
if a:matchline !~ a:prefix ..
|
||||
\ substitute(a:group, s:notslash .. '\zs:', '\\|', 'g') .. a:suffix
|
||||
return a:group
|
||||
endif
|
||||
let i = matchend(a:groupBR, s:notslash . ':')
|
||||
let i = matchend(a:groupBR, s:notslash .. ':')
|
||||
let ini = strpart(a:groupBR, 0, i-1)
|
||||
let tailBR = strpart(a:groupBR, i)
|
||||
let word = s:Choose(a:group, a:matchline, ":", "", a:prefix, a:suffix,
|
||||
\ a:groupBR)
|
||||
let i = matchend(word, s:notslash . ":")
|
||||
let i = matchend(word, s:notslash .. ":")
|
||||
let wordBR = strpart(word, i)
|
||||
let word = strpart(word, 0, i-1)
|
||||
" Now, a:matchline =~ a:prefix . word . a:suffix
|
||||
@@ -289,10 +302,10 @@ fun! s:InsertRefs(groupBR, prefix, group, suffix, matchline)
|
||||
let table = ""
|
||||
let d = 0
|
||||
while d < 10
|
||||
if tailBR =~ s:notslash . '\\' . d
|
||||
let table = table . d
|
||||
if tailBR =~ s:notslash .. '\\' .. d
|
||||
let table = table .. d
|
||||
else
|
||||
let table = table . "-"
|
||||
let table = table .. "-"
|
||||
endif
|
||||
let d = d + 1
|
||||
endwhile
|
||||
@@ -300,13 +313,13 @@ fun! s:InsertRefs(groupBR, prefix, group, suffix, matchline)
|
||||
let d = 9
|
||||
while d
|
||||
if table[d] != "-"
|
||||
let backref = substitute(a:matchline, a:prefix.word.a:suffix,
|
||||
\ '\'.table[d], "")
|
||||
let backref = substitute(a:matchline, a:prefix .. word .. a:suffix,
|
||||
\ '\' .. table[d], "")
|
||||
" Are there any other characters that should be escaped?
|
||||
let backref = escape(backref, '*,:')
|
||||
execute s:Ref(ini, d, "start", "len")
|
||||
let ini = strpart(ini, 0, start) . backref . strpart(ini, start+len)
|
||||
let tailBR = substitute(tailBR, s:notslash . '\zs\\' . d,
|
||||
let ini = strpart(ini, 0, start) .. backref .. strpart(ini, start+len)
|
||||
let tailBR = substitute(tailBR, s:notslash .. '\zs\\' .. d,
|
||||
\ escape(backref, '\\&'), 'g')
|
||||
endif
|
||||
let d = d-1
|
||||
@@ -320,7 +333,7 @@ fun! s:InsertRefs(groupBR, prefix, group, suffix, matchline)
|
||||
let b:match_word = ""
|
||||
endif
|
||||
endif
|
||||
return ini . ":" . tailBR
|
||||
return ini .. ":" .. tailBR
|
||||
endfun
|
||||
|
||||
" Input a comma-separated list of groups with backrefs, such as
|
||||
@@ -328,25 +341,25 @@ endfun
|
||||
" and return a comma-separated list of groups with backrefs replaced:
|
||||
" return '\(foo\):end\(foo\),\(bar\):end\(bar\)'
|
||||
fun! s:ParseWords(groups)
|
||||
let groups = substitute(a:groups.",", s:notslash.'\zs[,:]*,[,:]*', ',', 'g')
|
||||
let groups = substitute(groups, s:notslash . '\zs:\{2,}', ':', 'g')
|
||||
let groups = substitute(a:groups .. ",", s:notslash .. '\zs[,:]*,[,:]*', ',', 'g')
|
||||
let groups = substitute(groups, s:notslash .. '\zs:\{2,}', ':', 'g')
|
||||
let parsed = ""
|
||||
while groups =~ '[^,:]'
|
||||
let i = matchend(groups, s:notslash . ':')
|
||||
let j = matchend(groups, s:notslash . ',')
|
||||
let i = matchend(groups, s:notslash .. ':')
|
||||
let j = matchend(groups, s:notslash .. ',')
|
||||
let ini = strpart(groups, 0, i-1)
|
||||
let tail = strpart(groups, i, j-i-1) . ":"
|
||||
let tail = strpart(groups, i, j-i-1) .. ":"
|
||||
let groups = strpart(groups, j)
|
||||
let parsed = parsed . ini
|
||||
let i = matchend(tail, s:notslash . ':')
|
||||
let parsed = parsed .. ini
|
||||
let i = matchend(tail, s:notslash .. ':')
|
||||
while i != -1
|
||||
" In 'if:else:endif', ini='if' and word='else' and then word='endif'.
|
||||
let word = strpart(tail, 0, i-1)
|
||||
let tail = strpart(tail, i)
|
||||
let i = matchend(tail, s:notslash . ':')
|
||||
let parsed = parsed . ":" . s:Resolve(ini, word, "word")
|
||||
let i = matchend(tail, s:notslash .. ':')
|
||||
let parsed = parsed .. ":" .. s:Resolve(ini, word, "word")
|
||||
endwhile " Now, tail has been used up.
|
||||
let parsed = parsed . ","
|
||||
let parsed = parsed .. ","
|
||||
endwhile " groups =~ '[^,:]'
|
||||
let parsed = substitute(parsed, ',$', '', '')
|
||||
return parsed
|
||||
@@ -364,14 +377,14 @@ endfun
|
||||
" let j = matchend(getline("."), regexp)
|
||||
" let match = matchstr(getline("."), regexp)
|
||||
fun! s:Wholematch(string, pat, start)
|
||||
let group = '\%(' . a:pat . '\)'
|
||||
let prefix = (a:start ? '\(^.*\%<' . (a:start + 2) . 'c\)\zs' : '^')
|
||||
let group = '\%(' .. a:pat .. '\)'
|
||||
let prefix = (a:start ? '\(^.*\%<' .. (a:start + 2) .. 'c\)\zs' : '^')
|
||||
let len = strlen(a:string)
|
||||
let suffix = (a:start+1 < len ? '\(\%>'.(a:start+1).'c.*$\)\@=' : '$')
|
||||
if a:string !~ prefix . group . suffix
|
||||
let suffix = (a:start+1 < len ? '\(\%>' .. (a:start+1) .. 'c.*$\)\@=' : '$')
|
||||
if a:string !~ prefix .. group .. suffix
|
||||
let prefix = ''
|
||||
endif
|
||||
return prefix . group . suffix
|
||||
return prefix .. group .. suffix
|
||||
endfun
|
||||
|
||||
" No extra arguments: s:Ref(string, d) will
|
||||
@@ -392,7 +405,7 @@ fun! s:Ref(string, d, ...)
|
||||
let match = a:string
|
||||
while cnt
|
||||
let cnt = cnt - 1
|
||||
let index = matchend(match, s:notslash . '\\(')
|
||||
let index = matchend(match, s:notslash .. '\\(')
|
||||
if index == -1
|
||||
return ""
|
||||
endif
|
||||
@@ -404,7 +417,7 @@ fun! s:Ref(string, d, ...)
|
||||
endif
|
||||
let cnt = 1
|
||||
while cnt
|
||||
let index = matchend(match, s:notslash . '\\(\|\\)') - 1
|
||||
let index = matchend(match, s:notslash .. '\\(\|\\)') - 1
|
||||
if index == -2
|
||||
return ""
|
||||
endif
|
||||
@@ -418,7 +431,7 @@ fun! s:Ref(string, d, ...)
|
||||
if a:0 == 1
|
||||
return len
|
||||
elseif a:0 == 2
|
||||
return "let " . a:1 . "=" . start . "| let " . a:2 . "=" . len
|
||||
return "let " .. a:1 .. "=" .. start .. "| let " .. a:2 .. "=" .. len
|
||||
else
|
||||
return strpart(a:string, start, len)
|
||||
endif
|
||||
@@ -431,9 +444,9 @@ endfun
|
||||
fun! s:Count(string, pattern, ...)
|
||||
let pat = escape(a:pattern, '\\')
|
||||
if a:0 > 1
|
||||
let foo = substitute(a:string, '[^'.a:pattern.']', "a:1", "g")
|
||||
let foo = substitute(a:string, '[^' .. a:pattern .. ']', "a:1", "g")
|
||||
let foo = substitute(a:string, pat, a:2, "g")
|
||||
let foo = substitute(foo, '[^' . a:2 . ']', "", "g")
|
||||
let foo = substitute(foo, '[^' .. a:2 .. ']', "", "g")
|
||||
return strlen(foo)
|
||||
endif
|
||||
let result = 0
|
||||
@@ -456,7 +469,7 @@ endfun
|
||||
" unless it is preceded by "\".
|
||||
fun! s:Resolve(source, target, output)
|
||||
let word = a:target
|
||||
let i = matchend(word, s:notslash . '\\\d') - 1
|
||||
let i = matchend(word, s:notslash .. '\\\d') - 1
|
||||
let table = "----------"
|
||||
while i != -2 " There are back references to be replaced.
|
||||
let d = word[i]
|
||||
@@ -477,28 +490,28 @@ fun! s:Resolve(source, target, output)
|
||||
if table[s] == "-"
|
||||
if w + b < 10
|
||||
" let table[s] = w + b
|
||||
let table = strpart(table, 0, s) . (w+b) . strpart(table, s+1)
|
||||
let table = strpart(table, 0, s) .. (w+b) .. strpart(table, s+1)
|
||||
endif
|
||||
let b = b + 1
|
||||
let s = s + 1
|
||||
else
|
||||
execute s:Ref(backref, b, "start", "len")
|
||||
let ref = strpart(backref, start, len)
|
||||
let backref = strpart(backref, 0, start) . ":". table[s]
|
||||
\ . strpart(backref, start+len)
|
||||
let backref = strpart(backref, 0, start) .. ":" .. table[s]
|
||||
\ .. strpart(backref, start+len)
|
||||
let s = s + s:Count(substitute(ref, '\\\\', '', 'g'), '\(', '1')
|
||||
endif
|
||||
endwhile
|
||||
let word = strpart(word, 0, i-1) . backref . strpart(word, i+1)
|
||||
let i = matchend(word, s:notslash . '\\\d') - 1
|
||||
let word = strpart(word, 0, i-1) .. backref .. strpart(word, i+1)
|
||||
let i = matchend(word, s:notslash .. '\\\d') - 1
|
||||
endwhile
|
||||
let word = substitute(word, s:notslash . '\zs:', '\\', 'g')
|
||||
let word = substitute(word, s:notslash .. '\zs:', '\\', 'g')
|
||||
if a:output == "table"
|
||||
return table
|
||||
elseif a:output == "word"
|
||||
return word
|
||||
else
|
||||
return table . word
|
||||
return table .. word
|
||||
endif
|
||||
endfun
|
||||
|
||||
@@ -508,21 +521,21 @@ endfun
|
||||
" If <patn> is the first pattern that matches a:string then return <patn>
|
||||
" if no optional arguments are given; return <patn>,<altn> if a:1 is given.
|
||||
fun! s:Choose(patterns, string, comma, branch, prefix, suffix, ...)
|
||||
let tail = (a:patterns =~ a:comma."$" ? a:patterns : a:patterns . a:comma)
|
||||
let i = matchend(tail, s:notslash . a:comma)
|
||||
let tail = (a:patterns =~ a:comma .. "$" ? a:patterns : a:patterns .. a:comma)
|
||||
let i = matchend(tail, s:notslash .. a:comma)
|
||||
if a:0
|
||||
let alttail = (a:1 =~ a:comma."$" ? a:1 : a:1 . a:comma)
|
||||
let j = matchend(alttail, s:notslash . a:comma)
|
||||
let alttail = (a:1 =~ a:comma .. "$" ? a:1 : a:1 .. a:comma)
|
||||
let j = matchend(alttail, s:notslash .. a:comma)
|
||||
endif
|
||||
let current = strpart(tail, 0, i-1)
|
||||
if a:branch == ""
|
||||
let currpat = current
|
||||
else
|
||||
let currpat = substitute(current, s:notslash . a:branch, '\\|', 'g')
|
||||
let currpat = substitute(current, s:notslash .. a:branch, '\\|', 'g')
|
||||
endif
|
||||
while a:string !~ a:prefix . currpat . a:suffix
|
||||
while a:string !~ a:prefix .. currpat .. a:suffix
|
||||
let tail = strpart(tail, i)
|
||||
let i = matchend(tail, s:notslash . a:comma)
|
||||
let i = matchend(tail, s:notslash .. a:comma)
|
||||
if i == -1
|
||||
return -1
|
||||
endif
|
||||
@@ -530,15 +543,15 @@ fun! s:Choose(patterns, string, comma, branch, prefix, suffix, ...)
|
||||
if a:branch == ""
|
||||
let currpat = current
|
||||
else
|
||||
let currpat = substitute(current, s:notslash . a:branch, '\\|', 'g')
|
||||
let currpat = substitute(current, s:notslash .. a:branch, '\\|', 'g')
|
||||
endif
|
||||
if a:0
|
||||
let alttail = strpart(alttail, j)
|
||||
let j = matchend(alttail, s:notslash . a:comma)
|
||||
let j = matchend(alttail, s:notslash .. a:comma)
|
||||
endif
|
||||
endwhile
|
||||
if a:0
|
||||
let current = current . a:comma . strpart(alttail, 0, j-1)
|
||||
let current = current .. a:comma .. strpart(alttail, 0, j-1)
|
||||
endif
|
||||
return current
|
||||
endfun
|
||||
@@ -562,7 +575,7 @@ fun! matchit#Match_debug()
|
||||
" fin = 'endif' piece, with all backrefs resolved from match
|
||||
amenu &Matchit.&word :echo b:match_word<CR>
|
||||
" '\'.d in ini refers to the same thing as '\'.table[d] in word.
|
||||
amenu &Matchit.t&able :echo '0:' . b:match_table . ':9'<CR>
|
||||
amenu &Matchit.t&able :echo '0:' .. b:match_table .. ':9'<CR>
|
||||
endfun
|
||||
|
||||
" Jump to the nearest unmatched "(" or "if" or "<tag>" if a:spflag == "bW"
|
||||
@@ -598,26 +611,26 @@ fun! matchit#MultiMatch(spflag, mode)
|
||||
endif
|
||||
if (match_words != s:last_words) || (&mps != s:last_mps) ||
|
||||
\ exists("b:match_debug")
|
||||
let default = escape(&mps, '[$^.*~\\/?]') . (strlen(&mps) ? "," : "") .
|
||||
let default = escape(&mps, '[$^.*~\\/?]') .. (strlen(&mps) ? "," : "") ..
|
||||
\ '\/\*:\*\/,#\s*if\%(n\=def\)\=:#\s*else\>:#\s*elif\>:#\s*endif\>'
|
||||
let s:last_mps = &mps
|
||||
let match_words = match_words . (strlen(match_words) ? "," : "") . default
|
||||
let match_words = match_words .. (strlen(match_words) ? "," : "") .. default
|
||||
let s:last_words = match_words
|
||||
if match_words !~ s:notslash . '\\\d'
|
||||
if match_words !~ s:notslash .. '\\\d'
|
||||
let s:do_BR = 0
|
||||
let s:pat = match_words
|
||||
else
|
||||
let s:do_BR = 1
|
||||
let s:pat = s:ParseWords(match_words)
|
||||
endif
|
||||
let s:all = '\%(' . substitute(s:pat, '[,:]\+', '\\|', 'g') . '\)'
|
||||
let s:all = '\%(' .. substitute(s:pat, '[,:]\+', '\\|', 'g') .. '\)'
|
||||
if exists("b:match_debug")
|
||||
let b:match_pat = s:pat
|
||||
endif
|
||||
" Reconstruct the version with unresolved backrefs.
|
||||
let s:patBR = substitute(match_words.',',
|
||||
\ s:notslash.'\zs[,:]*,[,:]*', ',', 'g')
|
||||
let s:patBR = substitute(s:patBR, s:notslash.'\zs:\{2,}', ':', 'g')
|
||||
let s:patBR = substitute(match_words .. ',',
|
||||
\ s:notslash .. '\zs[,:]*,[,:]*', ',', 'g')
|
||||
let s:patBR = substitute(s:patBR, s:notslash .. '\zs:\{2,}', ':', 'g')
|
||||
endif
|
||||
|
||||
" Second step: figure out the patterns for searchpair()
|
||||
@@ -625,23 +638,23 @@ fun! matchit#MultiMatch(spflag, mode)
|
||||
" - TODO: A lot of this is copied from matchit#Match_wrapper().
|
||||
" - maybe even more functionality should be split off
|
||||
" - into separate functions!
|
||||
let openlist = split(s:pat . ',', s:notslash . '\zs:.\{-}' . s:notslash . ',')
|
||||
let midclolist = split(',' . s:pat, s:notslash . '\zs,.\{-}' . s:notslash . ':')
|
||||
call map(midclolist, {-> split(v:val, s:notslash . ':')})
|
||||
let openlist = split(s:pat .. ',', s:notslash .. '\zs:.\{-}' .. s:notslash .. ',')
|
||||
let midclolist = split(',' .. s:pat, s:notslash .. '\zs,.\{-}' .. s:notslash .. ':')
|
||||
call map(midclolist, {-> split(v:val, s:notslash .. ':')})
|
||||
let closelist = []
|
||||
let middlelist = []
|
||||
call map(midclolist, {i,v -> [extend(closelist, v[-1 : -1]),
|
||||
\ extend(middlelist, v[0 : -2])]})
|
||||
call map(openlist, {i,v -> v =~# s:notslash . '\\|' ? '\%(' . v . '\)' : v})
|
||||
call map(middlelist, {i,v -> v =~# s:notslash . '\\|' ? '\%(' . v . '\)' : v})
|
||||
call map(closelist, {i,v -> v =~# s:notslash . '\\|' ? '\%(' . v . '\)' : v})
|
||||
call map(openlist, {i,v -> v =~# s:notslash .. '\\|' ? '\%(' .. v .. '\)' : v})
|
||||
call map(middlelist, {i,v -> v =~# s:notslash .. '\\|' ? '\%(' .. v .. '\)' : v})
|
||||
call map(closelist, {i,v -> v =~# s:notslash .. '\\|' ? '\%(' .. v .. '\)' : v})
|
||||
let open = join(openlist, ',')
|
||||
let middle = join(middlelist, ',')
|
||||
let close = join(closelist, ',')
|
||||
if exists("b:match_skip")
|
||||
let skip = b:match_skip
|
||||
elseif exists("b:match_comment") " backwards compatibility and testing!
|
||||
let skip = "r:" . b:match_comment
|
||||
let skip = "r:" .. b:match_comment
|
||||
else
|
||||
let skip = 's:comment\|string'
|
||||
endif
|
||||
@@ -650,18 +663,18 @@ fun! matchit#MultiMatch(spflag, mode)
|
||||
|
||||
" Third step: call searchpair().
|
||||
" Replace '\('--but not '\\('--with '\%(' and ',' with '\|'.
|
||||
let openpat = substitute(open, '\%(' . s:notslash . '\)\@<=\\(', '\\%(', 'g')
|
||||
let openpat = substitute(open, '\%(' .. s:notslash .. '\)\@<=\\(', '\\%(', 'g')
|
||||
let openpat = substitute(openpat, ',', '\\|', 'g')
|
||||
let closepat = substitute(close, '\%(' . s:notslash . '\)\@<=\\(', '\\%(', 'g')
|
||||
let closepat = substitute(close, '\%(' .. s:notslash .. '\)\@<=\\(', '\\%(', 'g')
|
||||
let closepat = substitute(closepat, ',', '\\|', 'g')
|
||||
let middlepat = substitute(middle, '\%(' . s:notslash . '\)\@<=\\(', '\\%(', 'g')
|
||||
let middlepat = substitute(middle, '\%(' .. s:notslash .. '\)\@<=\\(', '\\%(', 'g')
|
||||
let middlepat = substitute(middlepat, ',', '\\|', 'g')
|
||||
|
||||
if skip =~ 'synID' && !(has("syntax") && exists("g:syntax_on"))
|
||||
let skip = '0'
|
||||
else
|
||||
try
|
||||
execute "if " . skip . "| let skip = '0' | endif"
|
||||
execute "if " .. skip .. "| let skip = '0' | endif"
|
||||
catch /^Vim\%((\a\+)\)\=:E363/
|
||||
" We won't find anything, so skip searching, should keep Vim responsive.
|
||||
return {}
|
||||
@@ -744,11 +757,11 @@ fun! s:ParseSkip(str)
|
||||
let skip = a:str
|
||||
if skip[1] == ":"
|
||||
if skip[0] == "s"
|
||||
let skip = "synIDattr(synID(line('.'),col('.'),1),'name') =~? '" .
|
||||
\ strpart(skip,2) . "'"
|
||||
let skip = "synIDattr(synID(line('.'),col('.'),1),'name') =~? '" ..
|
||||
\ strpart(skip,2) .. "'"
|
||||
elseif skip[0] == "S"
|
||||
let skip = "synIDattr(synID(line('.'),col('.'),1),'name') !~? '" .
|
||||
\ strpart(skip,2) . "'"
|
||||
let skip = "synIDattr(synID(line('.'),col('.'),1),'name') !~? '" ..
|
||||
\ strpart(skip,2) .. "'"
|
||||
elseif skip[0] == "r"
|
||||
let skip = "strpart(getline('.'),0,col('.'))=~'" . strpart(skip,2). "'"
|
||||
elseif skip[0] == "R"
|
||||
|
||||
15
runtime/pack/dist/opt/matchit/doc/matchit.txt
vendored
15
runtime/pack/dist/opt/matchit/doc/matchit.txt
vendored
@@ -1,10 +1,10 @@
|
||||
*matchit.txt* Extended "%" matching
|
||||
*matchit.txt* Extended "%" matching
|
||||
|
||||
For instructions on installing this file, type
|
||||
`:help matchit-install`
|
||||
inside Vim.
|
||||
|
||||
For Vim version 8.1. Last change: 2021 May 17
|
||||
For Vim version 8.2. Last change: 2021 Dec 24
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Benji Fisher et al
|
||||
@@ -148,6 +148,13 @@ To use the matchit plugin add this line to your |vimrc|: >
|
||||
|
||||
The script should start working the next time you start Vim.
|
||||
|
||||
To use the matching plugin after startup, you can use this command (note the
|
||||
omitted '!'): >
|
||||
packadd matchit
|
||||
|
||||
To use the matchit plugin after Vim has started, execute this command: >
|
||||
packadd matchit
|
||||
|
||||
(Earlier versions of the script did nothing unless a |buffer-variable| named
|
||||
|b:match_words| was defined. Even earlier versions contained autocommands
|
||||
that set this variable for various file types. Now, |b:match_words| is
|
||||
@@ -376,8 +383,8 @@ The back reference '\'.d refers to the same thing as '\'.b:match_table[d] in
|
||||
5. Known Bugs and Limitations *matchit-bugs*
|
||||
|
||||
Repository: https://github.com/chrisbra/matchit/
|
||||
Bugs can be reported at the repository (alternatively you can send me a mail).
|
||||
The latest development snapshot can also be downloaded there.
|
||||
Bugs can be reported at the repository and the latest development snapshot can
|
||||
also be downloaded there.
|
||||
|
||||
Just because I know about a bug does not mean that it is on my todo list. I
|
||||
try to respond to reports of bugs that cause real problems. If it does not
|
||||
|
||||
42
runtime/pack/dist/opt/matchit/plugin/matchit.vim
vendored
42
runtime/pack/dist/opt/matchit/plugin/matchit.vim
vendored
@@ -1,7 +1,7 @@
|
||||
" matchit.vim: (global plugin) Extended "%" matching
|
||||
" Maintainer: Christian Brabandt
|
||||
" Version: 1.17
|
||||
" Last Change: 2019 Oct 24
|
||||
" Version: 1.18
|
||||
" Last Change: 2020 Dec 23
|
||||
" Repository: https://github.com/chrisbra/matchit
|
||||
" Previous URL:http://www.vim.org/script.php?script_id=39
|
||||
" Previous Maintainer: Benji Fisher PhD <benji@member.AMS.org>
|
||||
@@ -48,18 +48,12 @@ set cpo&vim
|
||||
|
||||
nnoremap <silent> <Plug>(MatchitNormalForward) :<C-U>call matchit#Match_wrapper('',1,'n')<CR>
|
||||
nnoremap <silent> <Plug>(MatchitNormalBackward) :<C-U>call matchit#Match_wrapper('',0,'n')<CR>
|
||||
xnoremap <silent> <Plug>(MatchitVisualForward) :<C-U>call matchit#Match_wrapper('',1,'v')<CR>m'gv``
|
||||
xnoremap <silent> <Plug>(MatchitVisualForward) :<C-U>call matchit#Match_wrapper('',1,'v')<CR>
|
||||
\:if col("''") != col("$") \| exe ":normal! m'" \| endif<cr>gv``
|
||||
xnoremap <silent> <Plug>(MatchitVisualBackward) :<C-U>call matchit#Match_wrapper('',0,'v')<CR>m'gv``
|
||||
onoremap <silent> <Plug>(MatchitOperationForward) :<C-U>call matchit#Match_wrapper('',1,'o')<CR>
|
||||
onoremap <silent> <Plug>(MatchitOperationBackward) :<C-U>call matchit#Match_wrapper('',0,'o')<CR>
|
||||
|
||||
nmap <silent> % <Plug>(MatchitNormalForward)
|
||||
nmap <silent> g% <Plug>(MatchitNormalBackward)
|
||||
xmap <silent> % <Plug>(MatchitVisualForward)
|
||||
xmap <silent> g% <Plug>(MatchitVisualBackward)
|
||||
omap <silent> % <Plug>(MatchitOperationForward)
|
||||
omap <silent> g% <Plug>(MatchitOperationBackward)
|
||||
|
||||
" Analogues of [{ and ]} using matching patterns:
|
||||
nnoremap <silent> <Plug>(MatchitNormalMultiBackward) :<C-U>call matchit#MultiMatch("bW", "n")<CR>
|
||||
nnoremap <silent> <Plug>(MatchitNormalMultiForward) :<C-U>call matchit#MultiMatch("W", "n")<CR>
|
||||
@@ -68,16 +62,28 @@ xnoremap <silent> <Plug>(MatchitVisualMultiForward) :<C-U>call matchit#Multi
|
||||
onoremap <silent> <Plug>(MatchitOperationMultiBackward) :<C-U>call matchit#MultiMatch("bW", "o")<CR>
|
||||
onoremap <silent> <Plug>(MatchitOperationMultiForward) :<C-U>call matchit#MultiMatch("W", "o")<CR>
|
||||
|
||||
nmap <silent> [% <Plug>(MatchitNormalMultiBackward)
|
||||
nmap <silent> ]% <Plug>(MatchitNormalMultiForward)
|
||||
xmap <silent> [% <Plug>(MatchitVisualMultiBackward)
|
||||
xmap <silent> ]% <Plug>(MatchitVisualMultiForward)
|
||||
omap <silent> [% <Plug>(MatchitOperationMultiBackward)
|
||||
omap <silent> ]% <Plug>(MatchitOperationMultiForward)
|
||||
|
||||
" text object:
|
||||
xmap <silent> <Plug>(MatchitVisualTextObject) <Plug>(MatchitVisualMultiBackward)o<Plug>(MatchitVisualMultiForward)
|
||||
xmap a% <Plug>(MatchitVisualTextObject)
|
||||
|
||||
if !exists("g:no_plugin_maps")
|
||||
nmap <silent> % <Plug>(MatchitNormalForward)
|
||||
nmap <silent> g% <Plug>(MatchitNormalBackward)
|
||||
xmap <silent> % <Plug>(MatchitVisualForward)
|
||||
xmap <silent> g% <Plug>(MatchitVisualBackward)
|
||||
omap <silent> % <Plug>(MatchitOperationForward)
|
||||
omap <silent> g% <Plug>(MatchitOperationBackward)
|
||||
|
||||
" Analogues of [{ and ]} using matching patterns:
|
||||
nmap <silent> [% <Plug>(MatchitNormalMultiBackward)
|
||||
nmap <silent> ]% <Plug>(MatchitNormalMultiForward)
|
||||
xmap <silent> [% <Plug>(MatchitVisualMultiBackward)
|
||||
xmap <silent> ]% <Plug>(MatchitVisualMultiForward)
|
||||
omap <silent> [% <Plug>(MatchitOperationMultiBackward)
|
||||
omap <silent> ]% <Plug>(MatchitOperationMultiForward)
|
||||
|
||||
" Text object
|
||||
xmap a% <Plug>(MatchitVisualTextObject)
|
||||
endif
|
||||
|
||||
" Call this function to turn on debugging information. Every time the main
|
||||
" script is run, buffer variables will be saved. These can be used directly
|
||||
|
||||
373
runtime/pack/dist/opt/termdebug/plugin/termdebug.vim
vendored
373
runtime/pack/dist/opt/termdebug/plugin/termdebug.vim
vendored
@@ -2,7 +2,7 @@
|
||||
"
|
||||
" Author: Bram Moolenaar
|
||||
" Copyright: Vim license applies, see ":help license"
|
||||
" Last Change: 2021 Aug 23
|
||||
" Last Change: 2021 Dec 16
|
||||
"
|
||||
" WORK IN PROGRESS - Only the basics work
|
||||
" Note: On MS-Windows you need a recent version of gdb. The one included with
|
||||
@@ -96,6 +96,11 @@ endfunc
|
||||
|
||||
call s:Highlight(1, '', &background)
|
||||
hi default debugBreakpoint term=reverse ctermbg=red guibg=red
|
||||
hi default debugBreakpointDisabled term=reverse ctermbg=gray guibg=gray
|
||||
|
||||
func s:GetCommand()
|
||||
return type(g:termdebugger) == v:t_list ? copy(g:termdebugger) : [g:termdebugger]
|
||||
endfunc
|
||||
|
||||
func s:StartDebug(bang, ...)
|
||||
" First argument is the command to debug, second core file or process ID.
|
||||
@@ -112,8 +117,9 @@ func s:StartDebug_internal(dict)
|
||||
echoerr 'Terminal debugger already running, cannot run two'
|
||||
return
|
||||
endif
|
||||
if !executable(g:termdebugger)
|
||||
echoerr 'Cannot execute debugger program "' .. g:termdebugger .. '"'
|
||||
let gdbcmd = s:GetCommand()
|
||||
if !executable(gdbcmd[0])
|
||||
echoerr 'Cannot execute debugger program "' .. gdbcmd[0] .. '"'
|
||||
return
|
||||
endif
|
||||
|
||||
@@ -187,7 +193,7 @@ endfunc
|
||||
func s:CheckGdbRunning()
|
||||
let gdbproc = term_getjob(s:gdbbuf)
|
||||
if gdbproc == v:null || job_status(gdbproc) !=# 'run'
|
||||
echoerr string(g:termdebugger) . ' exited unexpectedly'
|
||||
echoerr string(s:GetCommand()[0]) . ' exited unexpectedly'
|
||||
call s:CloseBuffers()
|
||||
return ''
|
||||
endif
|
||||
@@ -229,14 +235,28 @@ func s:StartDebug_term(dict)
|
||||
endif
|
||||
let commpty = job_info(term_getjob(s:commbuf))['tty_out']
|
||||
|
||||
" Open a terminal window to run the debugger.
|
||||
" Add -quiet to avoid the intro message causing a hit-enter prompt.
|
||||
let gdb_args = get(a:dict, 'gdb_args', [])
|
||||
let proc_args = get(a:dict, 'proc_args', [])
|
||||
|
||||
let cmd = [g:termdebugger, '-quiet', '-tty', pty, '--eval-command', 'echo startupdone\n'] + gdb_args
|
||||
call ch_log('executing "' . join(cmd) . '"')
|
||||
let s:gdbbuf = term_start(cmd, {
|
||||
let gdb_cmd = s:GetCommand()
|
||||
" Add -quiet to avoid the intro message causing a hit-enter prompt.
|
||||
let gdb_cmd += ['-quiet']
|
||||
" Disable pagination, it causes everything to stop at the gdb
|
||||
let gdb_cmd += ['-iex', 'set pagination off']
|
||||
" Interpret commands while the target is running. This should usually only
|
||||
" be exec-interrupt, since many commands don't work properly while the
|
||||
" target is running (so execute during startup).
|
||||
let gdb_cmd += ['-iex', 'set mi-async on']
|
||||
" Open a terminal window to run the debugger.
|
||||
let gdb_cmd += ['-tty', pty]
|
||||
" Command executed _after_ startup is done, provides us with the necessary feedback
|
||||
let gdb_cmd += ['-ex', 'echo startupdone\n']
|
||||
|
||||
" Adding arguments requested by the user
|
||||
let gdb_cmd += gdb_args
|
||||
|
||||
call ch_log('executing "' . join(gdb_cmd) . '"')
|
||||
let s:gdbbuf = term_start(gdb_cmd, {
|
||||
\ 'term_finish': 'close',
|
||||
\ })
|
||||
if s:gdbbuf == 0
|
||||
@@ -255,8 +275,8 @@ func s:StartDebug_term(dict)
|
||||
|
||||
for lnum in range(1, 200)
|
||||
if term_getline(s:gdbbuf, lnum) =~ 'startupdone'
|
||||
let try_count = 9999
|
||||
break
|
||||
let try_count = 9999
|
||||
break
|
||||
endif
|
||||
endfor
|
||||
let try_count += 1
|
||||
@@ -269,11 +289,12 @@ func s:StartDebug_term(dict)
|
||||
|
||||
" Set arguments to be run.
|
||||
if len(proc_args)
|
||||
call term_sendkeys(s:gdbbuf, 'set args ' . join(proc_args) . "\r")
|
||||
call term_sendkeys(s:gdbbuf, 'server set args ' . join(proc_args) . "\r")
|
||||
endif
|
||||
|
||||
" Connect gdb to the communication pty, using the GDB/MI interface
|
||||
call term_sendkeys(s:gdbbuf, 'new-ui mi ' . commpty . "\r")
|
||||
" Connect gdb to the communication pty, using the GDB/MI interface.
|
||||
" Prefix "server" to avoid adding this to the history.
|
||||
call term_sendkeys(s:gdbbuf, 'server new-ui mi ' . commpty . "\r")
|
||||
|
||||
" Wait for the response to show up, users may not notice the error and wonder
|
||||
" why the debugger doesn't work.
|
||||
@@ -288,20 +309,21 @@ func s:StartDebug_term(dict)
|
||||
let line1 = term_getline(s:gdbbuf, lnum)
|
||||
let line2 = term_getline(s:gdbbuf, lnum + 1)
|
||||
if line1 =~ 'new-ui mi '
|
||||
" response can be in the same line or the next line
|
||||
let response = line1 . line2
|
||||
if response =~ 'Undefined command'
|
||||
echoerr 'Sorry, your gdb is too old, gdb 7.12 is required'
|
||||
call s:CloseBuffers()
|
||||
return
|
||||
endif
|
||||
if response =~ 'New UI allocated'
|
||||
" Success!
|
||||
break
|
||||
endif
|
||||
" response can be in the same line or the next line
|
||||
let response = line1 . line2
|
||||
if response =~ 'Undefined command'
|
||||
echoerr 'Sorry, your gdb is too old, gdb 7.12 is required'
|
||||
" CHECKME: possibly send a "server show version" here
|
||||
call s:CloseBuffers()
|
||||
return
|
||||
endif
|
||||
if response =~ 'New UI allocated'
|
||||
" Success!
|
||||
break
|
||||
endif
|
||||
elseif line1 =~ 'Reading symbols from' && line2 !~ 'new-ui mi '
|
||||
" Reading symbols might take a while, try more times
|
||||
let try_count -= 1
|
||||
" Reading symbols might take a while, try more times
|
||||
let try_count -= 1
|
||||
endif
|
||||
endfor
|
||||
if response =~ 'New UI allocated'
|
||||
@@ -315,17 +337,6 @@ func s:StartDebug_term(dict)
|
||||
sleep 10m
|
||||
endwhile
|
||||
|
||||
" Interpret commands while the target is running. This should usually only be
|
||||
" exec-interrupt, since many commands don't work properly while the target is
|
||||
" running.
|
||||
call s:SendCommand('-gdb-set mi-async on')
|
||||
" Older gdb uses a different command.
|
||||
call s:SendCommand('-gdb-set target-async on')
|
||||
|
||||
" Disable pagination, it causes everything to stop at the gdb
|
||||
" "Type <return> to continue" prompt.
|
||||
call s:SendCommand('set pagination off')
|
||||
|
||||
call job_setoptions(term_getjob(s:gdbbuf), {'exit_cb': function('s:EndTermDebug')})
|
||||
|
||||
" Set the filetype, this can be used to add mappings.
|
||||
@@ -355,14 +366,26 @@ func s:StartDebug_prompt(dict)
|
||||
exe (&columns / 2 - 1) . "wincmd |"
|
||||
endif
|
||||
|
||||
" Add -quiet to avoid the intro message causing a hit-enter prompt.
|
||||
let gdb_args = get(a:dict, 'gdb_args', [])
|
||||
let proc_args = get(a:dict, 'proc_args', [])
|
||||
|
||||
let cmd = [g:termdebugger, '-quiet', '--interpreter=mi2'] + gdb_args
|
||||
call ch_log('executing "' . join(cmd) . '"')
|
||||
let gdb_cmd = s:GetCommand()
|
||||
" Add -quiet to avoid the intro message causing a hit-enter prompt.
|
||||
let gdb_cmd += ['-quiet']
|
||||
" Disable pagination, it causes everything to stop at the gdb, needs to be run early
|
||||
let gdb_cmd += ['-iex', 'set pagination off']
|
||||
" Interpret commands while the target is running. This should usually only
|
||||
" be exec-interrupt, since many commands don't work properly while the
|
||||
" target is running (so execute during startup).
|
||||
let gdb_cmd += ['-iex', 'set mi-async on']
|
||||
" directly communicate via mi2
|
||||
let gdb_cmd += ['--interpreter=mi2']
|
||||
|
||||
let s:gdbjob = job_start(cmd, {
|
||||
" Adding arguments requested by the user
|
||||
let gdb_cmd += gdb_args
|
||||
|
||||
call ch_log('executing "' . join(gdb_cmd) . '"')
|
||||
let s:gdbjob = job_start(gdb_cmd, {
|
||||
\ 'exit_cb': function('s:EndPromptDebug'),
|
||||
\ 'out_cb': function('s:GdbOutCallback'),
|
||||
\ })
|
||||
@@ -375,13 +398,6 @@ func s:StartDebug_prompt(dict)
|
||||
set modified
|
||||
let s:gdb_channel = job_getchannel(s:gdbjob)
|
||||
|
||||
" Interpret commands while the target is running. This should usually only
|
||||
" be exec-interrupt, since many commands don't work properly while the
|
||||
" target is running.
|
||||
call s:SendCommand('-gdb-set mi-async on')
|
||||
" Older gdb uses a different command.
|
||||
call s:SendCommand('-gdb-set target-async on')
|
||||
|
||||
let s:ptybuf = 0
|
||||
if has('win32')
|
||||
" MS-Windows: run in a new console window for maximum compatibility
|
||||
@@ -415,8 +431,6 @@ func s:StartDebug_prompt(dict)
|
||||
endif
|
||||
call s:SendCommand('set print pretty on')
|
||||
call s:SendCommand('set breakpoint pending on')
|
||||
" Disable pagination, it causes everything to stop at the gdb
|
||||
call s:SendCommand('set pagination off')
|
||||
|
||||
" Set arguments to be run
|
||||
if len(proc_args)
|
||||
@@ -470,7 +484,7 @@ func s:StartDebugCommon(dict)
|
||||
" Run the command if the bang attribute was given and got to the debug
|
||||
" window.
|
||||
if get(a:dict, 'bang', 0)
|
||||
call s:SendCommand('-exec-run')
|
||||
call s:SendResumingCommand('-exec-run')
|
||||
call win_gotoid(s:ptywin)
|
||||
endif
|
||||
endfunc
|
||||
@@ -493,7 +507,7 @@ func TermDebugSendCommand(cmd)
|
||||
let do_continue = 0
|
||||
if !s:stopped
|
||||
let do_continue = 1
|
||||
call s:SendCommand('-exec-interrupt')
|
||||
Stop
|
||||
sleep 10m
|
||||
endif
|
||||
call term_sendkeys(s:gdbbuf, a:cmd . "\r")
|
||||
@@ -503,6 +517,20 @@ func TermDebugSendCommand(cmd)
|
||||
endif
|
||||
endfunc
|
||||
|
||||
" Send a command that resumes the program. If the program isn't stopped the
|
||||
" command is not sent (to avoid a repeated command to cause trouble).
|
||||
" If the command is sent then reset s:stopped.
|
||||
func s:SendResumingCommand(cmd)
|
||||
if s:stopped
|
||||
" reset s:stopped here, it may take a bit of time before we get a response
|
||||
let s:stopped = 0
|
||||
call ch_log('assume that program is running after this command')
|
||||
call s:SendCommand(a:cmd)
|
||||
else
|
||||
call ch_log('dropping command, program is running: ' . a:cmd)
|
||||
endif
|
||||
endfunc
|
||||
|
||||
" Function called when entering a line in the prompt buffer.
|
||||
func s:PromptCallback(text)
|
||||
call s:SendCommand(a:text)
|
||||
@@ -534,7 +562,7 @@ func s:GdbOutCallback(channel, text)
|
||||
if a:text == '(gdb) ' || a:text == '^done' || a:text[0] == '&'
|
||||
return
|
||||
endif
|
||||
if a:text =~ '^^error,msg='
|
||||
if a:text =~ '^\^error,msg='
|
||||
let text = s:DecodeMessage(a:text[11:])
|
||||
if exists('s:evalexpr') && text =~ 'A syntax error in expression, near\|No symbol .* in current context'
|
||||
" Silently drop evaluation errors.
|
||||
@@ -559,33 +587,33 @@ func s:GdbOutCallback(channel, text)
|
||||
endfunc
|
||||
|
||||
" Decode a message from gdb. quotedText starts with a ", return the text up
|
||||
" to the next ", unescaping characters.
|
||||
" to the next ", unescaping characters:
|
||||
" - remove line breaks
|
||||
" - change \\t to \t
|
||||
" - change \0xhh to \xhh (disabled for now)
|
||||
" - change \ooo to octal
|
||||
" - change \\ to \
|
||||
func s:DecodeMessage(quotedText)
|
||||
if a:quotedText[0] != '"'
|
||||
echoerr 'DecodeMessage(): missing quote in ' . a:quotedText
|
||||
return
|
||||
endif
|
||||
let result = ''
|
||||
let i = 1
|
||||
while a:quotedText[i] != '"' && i < len(a:quotedText)
|
||||
if a:quotedText[i] == '\'
|
||||
let i += 1
|
||||
if a:quotedText[i] == 'n'
|
||||
" drop \n
|
||||
let i += 1
|
||||
continue
|
||||
elseif a:quotedText[i] == 't'
|
||||
" append \t
|
||||
let i += 1
|
||||
let result .= "\t"
|
||||
continue
|
||||
endif
|
||||
endif
|
||||
let result .= a:quotedText[i]
|
||||
let i += 1
|
||||
endwhile
|
||||
return result
|
||||
return a:quotedText
|
||||
\ ->substitute('^"\|".*\|\\n', '', 'g')
|
||||
\ ->substitute('\\t', "\t", 'g')
|
||||
" multi-byte characters arrive in octal form
|
||||
" NULL-values must be kept encoded as those break the string otherwise
|
||||
\ ->substitute('\\000', s:NullRepl, 'g')
|
||||
\ ->substitute('\\\o\o\o', {-> eval('"' .. submatch(0) .. '"')}, 'g')
|
||||
" Note: GDB docs also mention hex encodings - the translations below work
|
||||
" but we keep them out for performance-reasons until we actually see
|
||||
" those in mi-returns
|
||||
" \ ->substitute('\\0x\(\x\x\)', {-> eval('"\x' .. submatch(1) .. '"')}, 'g')
|
||||
" \ ->substitute('\\0x00', s:NullRepl, 'g')
|
||||
\ ->substitute('\\\\', '\', 'g')
|
||||
\ ->substitute(s:NullRepl, '\\000', 'g')
|
||||
endfunc
|
||||
const s:NullRepl = 'XXXNULLXXX'
|
||||
|
||||
" Extract the "name" value from a gdb message with fullname="name".
|
||||
func s:GetFullname(msg)
|
||||
@@ -711,8 +739,8 @@ func s:HandleDisasmMsg(msg)
|
||||
|
||||
let lnum = search('^' . s:asm_addr)
|
||||
if lnum != 0
|
||||
exe 'sign unplace ' . s:asm_id
|
||||
exe 'sign place ' . s:asm_id . ' line=' . lnum . ' name=debugPC'
|
||||
exe 'sign unplace ' . s:asm_id
|
||||
exe 'sign place ' . s:asm_id . ' line=' . lnum . ' name=debugPC'
|
||||
endif
|
||||
|
||||
call win_gotoid(curwinid)
|
||||
@@ -736,9 +764,9 @@ func s:HandleDisasmMsg(msg)
|
||||
else
|
||||
let value = substitute(a:msg, '^\~\"[ ]*', '', '')
|
||||
let value = substitute(value, '^=>[ ]*', '', '')
|
||||
let value = substitute(value, '\\n\"
|
||||
let value = substitute(value, '\\n\"\r$', '', '')
|
||||
let value = substitute(value, '\\n\"$', '', '')
|
||||
let value = substitute(value, '\\n\"$', '', '')
|
||||
let value = substitute(value, '\r', '', '')
|
||||
let value = substitute(value, '\\t', ' ', 'g')
|
||||
|
||||
if value != '' || !empty(s:asm_lines)
|
||||
@@ -763,7 +791,9 @@ func s:CommOutput(chan, msg)
|
||||
if msg =~ '^\(\*stopped\|\*running\|=thread-selected\)'
|
||||
call s:HandleCursor(msg)
|
||||
elseif msg =~ '^\^done,bkpt=' || msg =~ '^=breakpoint-created,'
|
||||
call s:HandleCursor(msg)
|
||||
call s:HandleNewBreakpoint(msg, 0)
|
||||
elseif msg =~ '^=breakpoint-modified,'
|
||||
call s:HandleNewBreakpoint(msg, 1)
|
||||
elseif msg =~ '^=breakpoint-deleted,'
|
||||
call s:HandleBreakpointDelete(msg)
|
||||
elseif msg =~ '^=thread-group-started'
|
||||
@@ -773,8 +803,8 @@ func s:CommOutput(chan, msg)
|
||||
elseif msg =~ '^\^error,msg='
|
||||
call s:HandleError(msg)
|
||||
elseif msg =~ '^disassemble'
|
||||
call s:HandleError(msg)
|
||||
elseif msg =~ '^disassemble'
|
||||
let s:parsing_disasm_msg = 1
|
||||
let s:asm_lines = []
|
||||
endif
|
||||
endif
|
||||
endfor
|
||||
@@ -797,17 +827,20 @@ func s:InstallCommands()
|
||||
|
||||
command -nargs=? Break call s:SetBreakpoint(<q-args>)
|
||||
command Clear call s:ClearBreakpoint()
|
||||
command -nargs=? Break call s:SetBreakpoint(<q-args>)
|
||||
command Clear call s:ClearBreakpoint()
|
||||
command Step call s:SendCommand('-exec-step')
|
||||
command Step call s:SendResumingCommand('-exec-step')
|
||||
command Over call s:SendResumingCommand('-exec-next')
|
||||
command Finish call s:SendResumingCommand('-exec-finish')
|
||||
command -nargs=* Run call s:Run(<q-args>)
|
||||
command Finish call s:SendCommand('-exec-finish')
|
||||
command -nargs=* Run call s:Run(<q-args>)
|
||||
command -nargs=* Arguments call s:SendResumingCommand('-exec-arguments ' . <q-args>)
|
||||
|
||||
command Stop call s:SendCommand('-exec-interrupt')
|
||||
if s:way == 'prompt'
|
||||
command Stop call s:PromptInterrupt()
|
||||
command Continue call s:SendCommand('continue')
|
||||
else
|
||||
command Stop call s:SendCommand('-exec-interrupt')
|
||||
" using -exec-continue results in CTRL-C in the gdb window not working,
|
||||
" communicating via commbuf (= use of SendCommand) has the same result
|
||||
"command Continue call s:SendCommand('-exec-continue')
|
||||
command Continue call term_sendkeys(s:gdbbuf, "continue\r")
|
||||
endif
|
||||
|
||||
@@ -930,20 +963,16 @@ func s:SetBreakpoint(at)
|
||||
let do_continue = 0
|
||||
if !s:stopped
|
||||
let do_continue = 1
|
||||
if !s:stopped
|
||||
let do_continue = 1
|
||||
if s:way == 'prompt'
|
||||
call s:PromptInterrupt()
|
||||
else
|
||||
Stop
|
||||
sleep 10m
|
||||
endif
|
||||
|
||||
" Use the fname:lnum format, older gdb can't handle --source.
|
||||
let at = empty(a:at) ?
|
||||
" Use the fname:lnum format, older gdb can't handle --source.
|
||||
\ fnameescape(expand('%:p')) . ':' . line('.') : a:at
|
||||
call s:SendCommand('-break-insert ' . at)
|
||||
if do_continue
|
||||
call s:SendCommand('-break-insert ' . at)
|
||||
Continue
|
||||
endif
|
||||
endfunc
|
||||
|
||||
@@ -954,6 +983,7 @@ func s:ClearBreakpoint()
|
||||
let bploc = printf('%s:%d', fname, lnum)
|
||||
if has_key(s:breakpoint_locations, bploc)
|
||||
let idx = 0
|
||||
let nr = 0
|
||||
for id in s:breakpoint_locations[bploc]
|
||||
if has_key(s:breakpoints, id)
|
||||
" Assume this always works, the reply is simply "^done".
|
||||
@@ -963,46 +993,101 @@ func s:ClearBreakpoint()
|
||||
endfor
|
||||
unlet s:breakpoints[id]
|
||||
unlet s:breakpoint_locations[bploc][idx]
|
||||
let nr = id
|
||||
break
|
||||
else
|
||||
let idx += 1
|
||||
endif
|
||||
endfor
|
||||
endif
|
||||
endfor
|
||||
if nr != 0
|
||||
if empty(s:breakpoint_locations[bploc])
|
||||
unlet s:breakpoint_locations[bploc]
|
||||
endif
|
||||
echomsg 'Breakpoint ' . id . ' cleared from line ' . lnum . '.'
|
||||
else
|
||||
echoerr 'Internal error trying to remove breakpoint at line ' . lnum . '!'
|
||||
endif
|
||||
else
|
||||
echomsg 'No breakpoint to remove at line ' . lnum . '.'
|
||||
endif
|
||||
endfunc
|
||||
|
||||
func s:Run(args)
|
||||
if a:args != ''
|
||||
func s:Run(args)
|
||||
call s:SendResumingCommand('-exec-arguments ' . a:args)
|
||||
endif
|
||||
call s:SendCommand('-exec-arguments ' . a:args)
|
||||
call s:SendResumingCommand('-exec-run')
|
||||
endfunc
|
||||
|
||||
func s:SendEval(expr)
|
||||
|
||||
func s:SendEval(expr)
|
||||
" check for "likely" boolean expressions, in which case we take it as lhs
|
||||
if a:expr =~ "[=!<>]="
|
||||
let exprLHS = a:expr
|
||||
else
|
||||
" remove text that is likely an assignment
|
||||
let exprLHS = substitute(a:expr, ' *=.*', '', '')
|
||||
endif
|
||||
|
||||
" encoding expression to prevent bad errors
|
||||
let expr = a:expr
|
||||
let expr = substitute(expr, '\\', '\\\\', 'g')
|
||||
let expr = substitute(expr, '"', '\\"', 'g')
|
||||
call s:SendCommand('-data-evaluate-expression "' . expr . '"')
|
||||
let s:evalexpr = exprLHS
|
||||
endfunc
|
||||
|
||||
endfunc
|
||||
" :Evaluate - evaluate what is specified / under the cursor
|
||||
func s:Evaluate(range, arg)
|
||||
let expr = s:GetEvaluationExpression(a:range, a:arg)
|
||||
let s:ignoreEvalError = 0
|
||||
call s:SendEval(expr)
|
||||
endfunc
|
||||
|
||||
" get what is specified / under the cursor
|
||||
func s:GetEvaluationExpression(range, arg)
|
||||
if a:arg != ''
|
||||
func s:Evaluate(range, arg)
|
||||
" user supplied evaluation
|
||||
let expr = s:CleanupExpr(a:arg)
|
||||
" DSW: replace "likely copy + paste" assignment
|
||||
let expr = substitute(expr, '"\([^"]*\)": *', '\1=', 'g')
|
||||
elseif a:range == 2
|
||||
" no evaluation but provided but range set
|
||||
let pos = getcurpos()
|
||||
let reg = getreg('v', 1, 1)
|
||||
let regt = getregtype('v')
|
||||
normal! gv"vy
|
||||
let regt = getregtype('v')
|
||||
let expr = s:CleanupExpr(@v)
|
||||
call setpos('.', pos)
|
||||
call setreg('v', reg, regt)
|
||||
else
|
||||
" no evaluation provided: get from C-expression under cursor
|
||||
" TODO: allow filetype specific lookup #9057
|
||||
let expr = expand('<cexpr>')
|
||||
endif
|
||||
let expr = expand('<cexpr>')
|
||||
endif
|
||||
return expr
|
||||
endfunc
|
||||
|
||||
" clean up expression that may got in because of range
|
||||
" (newlines and surrounding whitespace)
|
||||
" As it can also be specified via ex-command for assignments this function
|
||||
" may not change the "content" parts (like replacing contained spaces
|
||||
func s:CleanupExpr(expr)
|
||||
" replace all embedded newlines/tabs/...
|
||||
let expr = substitute(a:expr, '\_s', ' ', 'g')
|
||||
|
||||
if &filetype ==# 'cobol'
|
||||
" extra cleanup for COBOL:
|
||||
" - a semicolon nmay be used instead of a space
|
||||
" - a trailing comma or period is ignored as it commonly separates/ends
|
||||
" multiple expr
|
||||
let expr = substitute(expr, ';', ' ', 'g')
|
||||
let expr = substitute(expr, '[,.]\+ *$', '', '')
|
||||
endif
|
||||
|
||||
" get rid of leading and trailing spaces
|
||||
let expr = substitute(expr, '^ *', '', '')
|
||||
let expr = substitute(expr, ' *$', '', '')
|
||||
return expr
|
||||
endfunc
|
||||
|
||||
let s:ignoreEvalError = 0
|
||||
@@ -1010,8 +1095,19 @@ let s:evalFromBalloonExpr = 0
|
||||
|
||||
" Handle the result of data-evaluate-expression
|
||||
func s:HandleEvaluate(msg)
|
||||
" Handle the result of data-evaluate-expression
|
||||
func s:HandleEvaluate(msg)
|
||||
let value = a:msg
|
||||
\ ->substitute('.*value="\(.*\)"', '\1', '')
|
||||
\ ->substitute('\\"', '"', 'g')
|
||||
\ ->substitute('\\\\', '\\', 'g')
|
||||
"\ multi-byte characters arrive in octal form, replace everthing but NULL values
|
||||
\ ->substitute('\\000', s:NullRepl, 'g')
|
||||
\ ->substitute('\\\o\o\o', {-> eval('"' .. submatch(0) .. '"')}, 'g')
|
||||
"\ Note: GDB docs also mention hex encodings - the translations below work
|
||||
"\ but we keep them out for performance-reasons until we actually see
|
||||
"\ those in mi-returns
|
||||
"\ ->substitute('\\0x00', s:NullRep, 'g')
|
||||
"\ ->substitute('\\0x\(\x\x\)', {-> eval('"\x' .. submatch(1) .. '"')}, 'g')
|
||||
\ ->substitute(s:NullRepl, '\\000', 'g')
|
||||
if s:evalFromBalloonExpr
|
||||
if s:evalFromBalloonExprResult == ''
|
||||
let s:evalFromBalloonExprResult = s:evalexpr . ': ' . value
|
||||
@@ -1046,7 +1142,8 @@ func TermDebugBalloonExpr()
|
||||
let s:evalFromBalloonExpr = 1
|
||||
let s:evalFromBalloonExprResult = ''
|
||||
let s:ignoreEvalError = 1
|
||||
let s:evalFromBalloonExprResult = ''
|
||||
let expr = s:CleanupExpr(v:beval_text)
|
||||
call s:SendEval(expr)
|
||||
return ''
|
||||
endfunc
|
||||
|
||||
@@ -1058,7 +1155,8 @@ func s:HandleError(msg)
|
||||
let s:evalFromBalloonExpr = 0
|
||||
return
|
||||
endif
|
||||
return
|
||||
let msgVal = substitute(a:msg, '.*msg="\(.*\)"', '\1', '')
|
||||
echoerr substitute(msgVal, '\\"', '"', 'g')
|
||||
endfunc
|
||||
|
||||
func s:GotoSourcewinOrCreateIt()
|
||||
@@ -1083,6 +1181,7 @@ func s:GotoAsmwinOrCreateIt()
|
||||
setlocal number
|
||||
setlocal noswapfile
|
||||
setlocal buftype=nofile
|
||||
setlocal modifiable
|
||||
|
||||
let asmbuf = bufnr('Termdebug-asm-listing')
|
||||
if asmbuf > 0
|
||||
@@ -1093,7 +1192,7 @@ func s:GotoAsmwinOrCreateIt()
|
||||
|
||||
if exists('g:termdebug_disasm_window')
|
||||
if g:termdebug_disasm_window > 1
|
||||
if exists('g:termdebug_disasm_window')
|
||||
exe 'resize ' . g:termdebug_disasm_window
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
@@ -1102,7 +1201,7 @@ func s:GotoAsmwinOrCreateIt()
|
||||
let lnum = search('^' . s:asm_addr)
|
||||
if lnum == 0
|
||||
if s:stopped
|
||||
if lnum == 0
|
||||
call s:SendCommand('disassemble $pc')
|
||||
endif
|
||||
else
|
||||
exe 'sign unplace ' . s:asm_id
|
||||
@@ -1137,15 +1236,15 @@ func s:HandleCursor(msg)
|
||||
|
||||
let curwinid = win_getid(winnr())
|
||||
if win_gotoid(s:asmwin)
|
||||
let curwinid = win_getid(winnr())
|
||||
if win_gotoid(s:asmwin)
|
||||
let lnum = search('^' . s:asm_addr)
|
||||
if lnum == 0
|
||||
call s:SendCommand('disassemble $pc')
|
||||
else
|
||||
exe 'sign unplace ' . s:asm_id
|
||||
let lnum = search('^' . s:asm_addr)
|
||||
if lnum == 0
|
||||
call s:SendCommand('disassemble $pc')
|
||||
else
|
||||
exe 'sign unplace ' . s:asm_id
|
||||
exe 'sign place ' . s:asm_id . ' line=' . lnum . ' name=debugPC'
|
||||
endif
|
||||
|
||||
endif
|
||||
call win_gotoid(curwinid)
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
@@ -1165,6 +1264,7 @@ func s:HandleCursor(msg)
|
||||
endif
|
||||
endif
|
||||
exe lnum
|
||||
normal! zv
|
||||
exe 'sign unplace ' . s:pc_id
|
||||
exe 'sign place ' . s:pc_id . ' line=' . lnum . ' name=debugPC priority=110 file=' . fname
|
||||
if !exists('b:save_signcolumn')
|
||||
@@ -1182,11 +1282,16 @@ endfunc
|
||||
|
||||
let s:BreakpointSigns = []
|
||||
|
||||
let s:BreakpointSigns = []
|
||||
func s:CreateBreakpoint(id, subid, enabled)
|
||||
let nr = printf('%d.%d', a:id, a:subid)
|
||||
if index(s:BreakpointSigns, nr) == -1
|
||||
call add(s:BreakpointSigns, nr)
|
||||
if index(s:BreakpointSigns, nr) == -1
|
||||
if a:enabled == "n"
|
||||
let hiName = "debugBreakpointDisabled"
|
||||
else
|
||||
let hiName = "debugBreakpoint"
|
||||
endif
|
||||
exe "sign define debugBreakpoint" . nr . " text=" . substitute(nr, '\..*', '', '') . " texthl=" . hiName
|
||||
endif
|
||||
endfunc
|
||||
|
||||
@@ -1196,9 +1301,14 @@ endfunction
|
||||
|
||||
" Handle setting a breakpoint
|
||||
" Will update the sign that shows the breakpoint
|
||||
" Handle setting a breakpoint
|
||||
func s:HandleNewBreakpoint(msg, modifiedFlag)
|
||||
if a:msg !~ 'fullname='
|
||||
func s:HandleNewBreakpoint(msg)
|
||||
" a watch or a pending breakpoint does not have a file name
|
||||
if a:msg =~ 'pending='
|
||||
let nr = substitute(a:msg, '.*number=\"\([0-9.]*\)\".*', '\1', '')
|
||||
let target = substitute(a:msg, '.*pending=\"\([^"]*\)\".*', '\1', '')
|
||||
echomsg 'Breakpoint ' . nr . ' (' . target . ') pending.'
|
||||
endif
|
||||
return
|
||||
endif
|
||||
for msg in s:SplitMsg(a:msg)
|
||||
@@ -1214,7 +1324,8 @@ func s:HandleNewBreakpoint(msg)
|
||||
" If "nr" is 123 it becomes "123.0" and subid is "0".
|
||||
" If "nr" is 123.4 it becomes "123.4.0" and subid is "4"; "0" is discarded.
|
||||
let [id, subid; _] = map(split(nr . '.0', '\.'), 'v:val + 0')
|
||||
" If "nr" is 123.4 it becomes "123.4.0" and subid is "4"; "0" is discarded.
|
||||
let enabled = substitute(msg, '.*enabled="\([yn]\)".*', '\1', '')
|
||||
call s:CreateBreakpoint(id, subid, enabled)
|
||||
|
||||
if has_key(s:breakpoints, id)
|
||||
let entries = s:breakpoints[id]
|
||||
@@ -1241,7 +1352,18 @@ func s:HandleNewBreakpoint(msg)
|
||||
|
||||
if bufloaded(fname)
|
||||
call s:PlaceSign(id, subid, entry)
|
||||
let posMsg = ' at line ' . lnum . '.'
|
||||
else
|
||||
let posMsg = ' in ' . fname . ' at line ' . lnum . '.'
|
||||
endif
|
||||
if !a:modifiedFlag
|
||||
let actionTaken = 'created'
|
||||
elseif enabled == 'n'
|
||||
let actionTaken = 'disabled'
|
||||
else
|
||||
let actionTaken = 'enabled'
|
||||
endif
|
||||
echomsg 'Breakpoint ' . nr . ' ' . actionTaken . posMsg
|
||||
endfor
|
||||
endfunc
|
||||
|
||||
@@ -1266,6 +1388,7 @@ func s:HandleBreakpointDelete(msg)
|
||||
endif
|
||||
endfor
|
||||
unlet s:breakpoints[id]
|
||||
echomsg 'Breakpoint ' . id . ' cleared.'
|
||||
endif
|
||||
endfunc
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
if &cp || exists("g:loaded_zipPlugin")
|
||||
finish
|
||||
endif
|
||||
let g:loaded_zipPlugin = "v31"
|
||||
let g:loaded_zipPlugin = "v32"
|
||||
let s:keepcpo = &cpo
|
||||
set cpo&vim
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user