Mercurial > vim
annotate README.md @ 33776:9503dc55b5ed v9.0.2108
patch 9.0.2108: [security]: overflow with count for :s command
Commit: https://github.com/vim/vim/commit/ac63787734fda2e294e477af52b3bd601517fa78
Author: Christian Brabandt <cb@256bit.org>
Date: Tue Nov 14 20:45:48 2023 +0100
patch 9.0.2108: [security]: overflow with count for :s command
Problem: [security]: overflow with count for :s command
Solution: Abort the :s command if the count is too large
If the count after the :s command is larger than what fits into a
(signed) long variable, abort with e_value_too_large.
Adds a test with INT_MAX as count and verify it correctly fails.
It seems the return value on Windows using mingw compiler wraps around,
so the initial test using :s/./b/9999999999999999999999999990 doesn't
fail there, since the count is wrapping around several times and finally
is no longer larger than 2147483647. So let's just use 2147483647 in the
test, which hopefully will always cause a failure
Signed-off-by: Christian Brabandt <cb@256bit.org>
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Thu, 16 Nov 2023 22:15:10 +0100 |
parents | aaa5c1db3731 |
children | 4635e43f2c6f |
rev | line source |
---|---|
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
1 # [![Vim The editor](https://github.com/vim/vim/raw/master/runtime/vimlogo.gif)](https://www.vim.org) |
23327 | 2 |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
3 [![Github Build status](https://github.com/vim/vim/workflows/GitHub%20CI/badge.svg)](https://github.com/vim/vim/actions?query=workflow%3A%22GitHub+CI%22) |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
4 [![Appveyor Build status](https://ci.appveyor.com/api/projects/status/o2qht2kjm02sgghk?svg=true)](https://ci.appveyor.com/project/chrisbra/vim) |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
5 [![Cirrus Build Status](https://api.cirrus-ci.com/github/vim/vim.svg)](https://cirrus-ci.com/github/vim/vim) |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
6 [![Coverage Status](https://codecov.io/gh/vim/vim/coverage.svg?branch=master)](https://codecov.io/gh/vim/vim?branch=master) |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
7 [![Coverity Scan](https://scan.coverity.com/projects/241/badge.svg)](https://scan.coverity.com/projects/vim) |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
8 [![Debian CI](https://badges.debian.net/badges/debian/testing/vim/version.svg)](https://buildd.debian.org/vim) |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
9 [![Packages](https://repology.org/badge/tiny-repos/vim.svg)](https://repology.org/metapackage/vim) |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
10 [![Fossies codespell report](https://fossies.org/linux/test/vim-master.tar.gz/codespell.svg)](https://fossies.org/linux/test/vim-master.tar.gz/codespell.html) |
6916 | 11 |
24892
e73a9667e471
Add links to discussion forums.
Bram Moolenaar <Bram@vim.org>
parents:
24468
diff
changeset
|
12 If you find a bug or want to discuss the best way to add a new feature, please |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
13 [open an issue](https://github.com/vim/vim/issues/new/choose). |
24892
e73a9667e471
Add links to discussion forums.
Bram Moolenaar <Bram@vim.org>
parents:
24468
diff
changeset
|
14 If you have a question or want to discuss the best way to do something with |
e73a9667e471
Add links to discussion forums.
Bram Moolenaar <Bram@vim.org>
parents:
24468
diff
changeset
|
15 Vim, you can use [StackExchange](https://vi.stackexchange.com/) |
e73a9667e471
Add links to discussion forums.
Bram Moolenaar <Bram@vim.org>
parents:
24468
diff
changeset
|
16 or one of the [Maillists](https://www.vim.org/community.php). |
e73a9667e471
Add links to discussion forums.
Bram Moolenaar <Bram@vim.org>
parents:
24468
diff
changeset
|
17 |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
18 ## What is Vim? |
6916 | 19 |
24468 | 20 Vim is a greatly improved version of the good old UNIX editor |
21 [Vi](https://en.wikipedia.org/wiki/Vi). Many new | |
8791
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
22 features have been added: multi-level undo, syntax highlighting, command line |
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
23 history, on-line help, spell checking, filename completion, block operations, |
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
24 script language, etc. There is also a Graphical User Interface (GUI) |
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
25 available. Still, Vi compatibility is maintained, those who have Vi "in the |
24468 | 26 fingers" will feel at home. |
27 See [`runtime/doc/vi_diff.txt`](runtime/doc/vi_diff.txt) for differences with | |
8791
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
28 Vi. |
6916 | 29 |
30 This editor is very useful for editing programs and other plain text files. | |
31 All commands are given with normal keyboard characters, so those who can type | |
32 with ten fingers can work very fast. Additionally, function keys can be | |
8791
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
33 mapped to commands by the user, and the mouse can be used. |
6916 | 34 |
30320
0763cb330a65
patch 9.0.0496: no good reason to keep supporting Windows-XP
Bram Moolenaar <Bram@vim.org>
parents:
29533
diff
changeset
|
35 Vim runs under MS-Windows (7, 8, 10, 11), macOS, Haiku, VMS and almost all |
0763cb330a65
patch 9.0.0496: no good reason to keep supporting Windows-XP
Bram Moolenaar <Bram@vim.org>
parents:
29533
diff
changeset
|
36 flavours of UNIX. Porting to other systems should not be very difficult. |
0763cb330a65
patch 9.0.0496: no good reason to keep supporting Windows-XP
Bram Moolenaar <Bram@vim.org>
parents:
29533
diff
changeset
|
37 Older versions of Vim run on MS-DOS, MS-Windows 95/98/Me/NT/2000/XP/Vista, |
0763cb330a65
patch 9.0.0496: no good reason to keep supporting Windows-XP
Bram Moolenaar <Bram@vim.org>
parents:
29533
diff
changeset
|
38 Amiga DOS, Atari MiNT, BeOS, RISC OS and OS/2. These are no longer maintained. |
6916 | 39 |
19181
94eda51ba9ba
patch 8.2.0149: maintaining a Vim9 branch separately is more work
Bram Moolenaar <Bram@vim.org>
parents:
19125
diff
changeset
|
40 For Vim9 script see [README_VIM9](README_VIM9.md). |
94eda51ba9ba
patch 8.2.0149: maintaining a Vim9 branch separately is more work
Bram Moolenaar <Bram@vim.org>
parents:
19125
diff
changeset
|
41 |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
42 ## Distribution |
6916 | 43 |
7177
c4d677c50b9b
commit https://github.com/vim/vim/commit/c92399f4ee6d0289dbe5d708d14a84e32f617bd5
Christian Brabandt <cb@256bit.org>
parents:
7137
diff
changeset
|
44 You can often use your favorite package manager to install Vim. On Mac and |
c4d677c50b9b
commit https://github.com/vim/vim/commit/c92399f4ee6d0289dbe5d708d14a84e32f617bd5
Christian Brabandt <cb@256bit.org>
parents:
7137
diff
changeset
|
45 Linux a small version of Vim is pre-installed, you still need to install Vim |
c4d677c50b9b
commit https://github.com/vim/vim/commit/c92399f4ee6d0289dbe5d708d14a84e32f617bd5
Christian Brabandt <cb@256bit.org>
parents:
7137
diff
changeset
|
46 if you want more features. |
c4d677c50b9b
commit https://github.com/vim/vim/commit/c92399f4ee6d0289dbe5d708d14a84e32f617bd5
Christian Brabandt <cb@256bit.org>
parents:
7137
diff
changeset
|
47 |
6916 | 48 There are separate distributions for Unix, PC, Amiga and some other systems. |
49 This `README.md` file comes with the runtime archive. It includes the | |
50 documentation, syntax files and other files that are used at runtime. To run | |
51 Vim you must get either one of the binary archives or a source archive. | |
52 Which one you need depends on the system you want to run it on and whether you | |
25700 | 53 want or must compile it yourself. Check https://www.vim.org/download.php for |
6916 | 54 an overview of currently available distributions. |
55 | |
8917
d07e51166f08
commit https://github.com/vim/vim/commit/5d98c9d93278d6961bfee59151666b8a8bcd23c3
Christian Brabandt <cb@256bit.org>
parents:
8791
diff
changeset
|
56 Some popular places to get the latest Vim: |
24468 | 57 * Check out the git repository from [GitHub](https://github.com/vim/vim). |
8917
d07e51166f08
commit https://github.com/vim/vim/commit/5d98c9d93278d6961bfee59151666b8a8bcd23c3
Christian Brabandt <cb@256bit.org>
parents:
8791
diff
changeset
|
58 * Get the source code as an [archive](https://github.com/vim/vim/releases). |
d07e51166f08
commit https://github.com/vim/vim/commit/5d98c9d93278d6961bfee59151666b8a8bcd23c3
Christian Brabandt <cb@256bit.org>
parents:
8791
diff
changeset
|
59 * Get a Windows executable from the |
d07e51166f08
commit https://github.com/vim/vim/commit/5d98c9d93278d6961bfee59151666b8a8bcd23c3
Christian Brabandt <cb@256bit.org>
parents:
8791
diff
changeset
|
60 [vim-win32-installer](https://github.com/vim/vim-win32-installer/releases) repository. |
d07e51166f08
commit https://github.com/vim/vim/commit/5d98c9d93278d6961bfee59151666b8a8bcd23c3
Christian Brabandt <cb@256bit.org>
parents:
8791
diff
changeset
|
61 |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
62 ## Compiling |
8791
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
63 |
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
64 If you obtained a binary distribution you don't need to compile Vim. If you |
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
65 obtained a source distribution, all the stuff for compiling Vim is in the |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
66 [`src`](./src/) directory. See [`src/INSTALL`](./src/INSTALL) for instructions. |
8791
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
67 |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
68 ## Installation |
8791
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
69 |
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
70 See one of these files for system-specific instructions. Either in the |
24468 | 71 [READMEdir directory](./READMEdir/) (in the repository) or |
72 the top directory (if you unpack an archive): | |
8791
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
73 |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
74 ``` |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
75 README_ami.txt Amiga |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
76 README_unix.txt Unix |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
77 README_dos.txt MS-DOS and MS-Windows |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
78 README_mac.txt Macintosh |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
79 README_haiku.txt Haiku |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
80 README_vms.txt VMS |
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
81 ``` |
8791
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
82 |
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
83 There are other `README_*.txt` files, depending on the distribution you used. |
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
84 |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
85 ## Documentation |
6916 | 86 |
8791
43b5ff7837ea
commit https://github.com/vim/vim/commit/d18cfb7dbfd32af729d3ac5136f77dcdbefe5dee
Christian Brabandt <cb@256bit.org>
parents:
8619
diff
changeset
|
87 The Vim tutor is a one hour training course for beginners. Often it can be |
6916 | 88 started as `vimtutor`. See `:help tutor` for more information. |
89 | |
90 The best is to use `:help` in Vim. If you don't have an executable yet, read | |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
91 [`runtime/doc/help.txt`](./runtime/doc/help.txt). |
24468 | 92 It contains pointers to the other documentation files. |
93 The User Manual reads like a book and is recommended to learn to use | |
6916 | 94 Vim. See `:help user-manual`. |
95 | |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
96 ## Copying |
6916 | 97 |
98 Vim is Charityware. You can use and copy it as much as you like, but you are | |
99 encouraged to make a donation to help orphans in Uganda. Please read the file | |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
100 [`runtime/doc/uganda.txt`](./runtime/doc/uganda.txt) |
24468 | 101 for details (do `:help uganda` inside Vim). |
6916 | 102 |
103 Summary of the license: There are no restrictions on using or distributing an | |
104 unmodified copy of Vim. Parts of Vim may also be distributed, but the license | |
31579 | 105 text must always be included. For modified versions, a few restrictions apply. |
6916 | 106 The license is GPL compatible, you may compile Vim with GPL libraries and |
107 distribute it. | |
108 | |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
109 ## Sponsoring |
6916 | 110 |
111 Fixing bugs and adding new features takes a lot of time and effort. To show | |
112 your appreciation for the work and motivate Bram and others to continue | |
113 working on Vim please send a donation. | |
114 | |
115 Since Bram is back to a paid job the money will now be used to help children | |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
116 in Uganda. See [`runtime/doc/uganda.txt`](./runtime/doc/uganda.txt). But |
24468 | 117 at the same time donations increase Bram's motivation to keep working on Vim! |
6916 | 118 |
119 For the most recent information about sponsoring look on the Vim web site: | |
25700 | 120 https://www.vim.org/sponsor/ |
6916 | 121 |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
122 ## Contributing |
7127
e945a8e35535
commit https://github.com/vim/vim/commit/3fe076f0feb91460266fdf7f9133a59c49a53c4e
Christian Brabandt <cb@256bit.org>
parents:
6916
diff
changeset
|
123 |
31579 | 124 If you would like to help make Vim better, see the |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
125 [CONTRIBUTING.md](./CONTRIBUTING.md) file. |
7127
e945a8e35535
commit https://github.com/vim/vim/commit/3fe076f0feb91460266fdf7f9133a59c49a53c4e
Christian Brabandt <cb@256bit.org>
parents:
6916
diff
changeset
|
126 |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
127 ## Information |
6916 | 128 |
29533 | 129 If you are on macOS, you can use [Macvim](https://macvim-dev.github.io/macvim/). |
130 | |
6916 | 131 The latest news about Vim can be found on the Vim home page: |
25700 | 132 https://www.vim.org/ |
6916 | 133 |
134 If you have problems, have a look at the Vim documentation or tips: | |
25700 | 135 https://www.vim.org/docs.php |
136 https://vim.fandom.com/wiki/Vim_Tips_Wiki | |
6916 | 137 |
138 If you still have problems or any other questions, use one of the mailing | |
139 lists to discuss them with Vim users and developers: | |
25700 | 140 https://www.vim.org/maillist.php |
6916 | 141 |
32770
4027cefc2aab
Farewell to Bram and dedicate upcoming Vim 9.1 to him (#12749)
Christian Brabandt <cb@256bit.org>
parents:
31676
diff
changeset
|
142 If nothing else works, report bugs directly to the vim-dev mailing list: |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
143 `<vim-dev@vim.org>` |
6916 | 144 |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
145 ## Main author |
6916 | 146 |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
147 Most of Vim was created by Bram Moolenaar `<Bram@vim.org>` |
32774
1b2730ece70e
runtime: Add a few more remarks about Bram and new runtime files
Christian Brabandt <cb@256bit.org>
parents:
32770
diff
changeset
|
148 [Bram-Moolenaar](https://vimhelp.org/version9.txt.html#Bram-Moolenaar) |
1b2730ece70e
runtime: Add a few more remarks about Bram and new runtime files
Christian Brabandt <cb@256bit.org>
parents:
32770
diff
changeset
|
149 |
32770
4027cefc2aab
Farewell to Bram and dedicate upcoming Vim 9.1 to him (#12749)
Christian Brabandt <cb@256bit.org>
parents:
31676
diff
changeset
|
150 Send any other comments, patches, flowers and suggestions to the vim-dev mailing list: |
32878
aaa5c1db3731
docs: Improve Markdown in README (#12829)
Christian Brabandt <cb@256bit.org>
parents:
32774
diff
changeset
|
151 `<vim-dev@vim.org>` |
14119
b5b0b87f1a39
patch 8.1.0077: header of README file is not nice
Christian Brabandt <cb@256bit.org>
parents:
14115
diff
changeset
|
152 |
29314 | 153 This is `README.md` for version 9.0 of Vim: Vi IMproved. |