| Commit message (Collapse) | Author | Age |
... | |
|
|
|
|
|
| |
Problem: Setting 'encoding' makes 'printheader' invalid.
Solution: Do not translate the default value of 'printheader'. (Yasuhiro
Matsumoto, closes vim/vim#2026)
https://github.com/vim/vim/commit/0903d56f5ca69bb1fa0bbb00ed2a3d9c4d06ddb4
|
|
|
| |
">%s 2>&1" redirects stderr to a file, same as 'shellredir' on Windows.
|
|
|
|
|
|
| |
Because we default to laststatus=2 (statusline is always visible), the
:edit message is not useful.
ref #6289
|
| |
|
|
|
|
|
|
|
| |
Problem: ":set scroll&" often gives an error.
Solution: Don't use a fixed default value, use half the window height. Add a
test. (Ozaki Kiichi, closes vim/vim#2104)
https://github.com/vim/vim/commit/af2d20c6285c1d2973e3d9b5e8f727e3ed180493
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
After this change we never release blocks from memory (in practice it
never happened because the memory limits are never reached). Let the OS
take care of that.
---
On today's systems the 'maxmem' and 'maxmemtot' values are huge (4+ GB)
so the limits are never reached in practice, but Vim wastes a lot of
time checking if the limit was reached.
If the limit is reached Vim starts saving pieces of the swap file that were in
memory to the disk. Said in a different way: Vim implements its own
memory-paging mechanism. This is unnecessary and inefficient since the
operating system already has virtual memory and will swap to the disk if
programs start using too much memory.
This change does...
1. Reduce the number of config options and need for documentation.
2. Make the code more efficient as we don't have to keep track of memory
usage nor check if the memory limits were reached to start swapping
to disk every time we need memory for buffers.
3. Simplify the code. Once memfile.c is simple enough it could be
replaced by actual operating system memory mapping (mmap,
MemoryViewOfFile...). This change does not prevent Vim to recover
changes from swap files since the swapping code is never triggered
with the huge limits set by default.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
> The option 'maxmem' ('mm') is used to set the maximum memory used for one
> buffer (in kilobytes). 'maxmemtot' is used to set the maximum memory used for
> all buffers (in kilobytes). The defaults depend on the system used. These
> are not hard limits, but tell Vim when to move text into a swap file. If you
> don't like Vim to swap to a file, set 'maxmem' and 'maxmemtot' to a very large
> value. The swap file will then only be used for recovery. If you don't want
> a swap file at all, set 'updatecount' to 0, or use the "-n" argument when
> starting Vim.
On today's systems these values are huge (4GB in my machine with 8GB of RAM
since it's set as half the available memory by default) so the limits are
never reached in practice, but Vim wastes a lot of time checking if the limit
was reached.
If the limit is reached Vim starts saving pieces of the swap file that were in
memory to the disk. Said in a different way: Vim implements its own memory
swapping mechanism. This is unnecessary and inefficient since the operating
system already virtualized the memory and will swap to the disk if programs
start using too much memory.
This change does...
1. Reduce the number of config options and need for documentation.
2. Make the code more efficient as we don't have to keep track of memory usage
nor check if the memory limits were reached to start swapping to disk every
time we need memory for buffers.
3. Simplify the code. Once `memfile.c` is simple enough it could be replaced by
actual operating system memory mapping (`mmap`, `MemoryViewOfFile`...).
This change does not prevent Vim to recover changes from swap files since the
swapping code is never triggered with the huge limits set by default.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
ref #6725
fsync() is very slow on some systems. And since the parent commit, Nvim
is smarter about flushing files at certain times (e.g. CursorHold),
regardless of whether 'fsync' is enabled. So it's less risky to disable
'fsync'.
Profiling showed slow (2-4s) :write and :quit caused by fsync():
:quit
shada_write_file(NULL, false);
:write + fsync
0 0x00007f72da567b2d in fsync () at ../sysdeps/unix/syscall-template.S:84
1 0x0000000000638970 in uv__fs_fsync (req=<optimized out>) at /home/vagrant/neovim/.deps/build/src/libuv/src/unix/fs.c:150
2 uv__fs_work (w=<optimized out>) at /home/vagrant/neovim/.deps/build/src/libuv/src/unix/fs.c:953
3 0x0000000000639a70 in uv_fs_fsync (loop=<optimized out>, req=<optimized out>, file=41, cb=0x7f72da567b2d <fsync+45>)
at /home/vagrant/neovim/.deps/build/src/libuv/src/unix/fs.c:1094
4 0x0000000000573694 in os_fsync (fd=41) at ../src/nvim/os/fs.c:631
5 0x00000000004ec9dc in buf_write (buf=<optimized out>, fname=<optimized out>, sfname=<optimized out>, start=1, end=1997, eap=0x7fffc864c570,
append=<optimized out>, forceit=<optimized out>, reset_changed=<optimized out>, filtering=<optimized out>) at ../src/nvim/fileio.c:3387
6 0x00000000004b44ff in do_write (eap=0x7fffc864c570) at ../src/nvim/ex_cmds.c:1745
...
:write + nofsync
0 0x00007f72da567b2d in fsync () at ../sysdeps/unix/syscall-template.S:84
1 0x0000000000638970 in uv__fs_fsync (req=<optimized out>) at /home/vagrant/neovim/.deps/build/src/libuv/src/unix/fs.c:150
2 uv__fs_work (w=<optimized out>) at /home/vagrant/neovim/.deps/build/src/libuv/src/unix/fs.c:953
3 0x0000000000639a70 in uv_fs_fsync (loop=<optimized out>, req=<optimized out>, file=36, cb=0x7f72da567b2d <fsync+45>)
at /home/vagrant/neovim/.deps/build/src/libuv/src/unix/fs.c:1094
4 0x0000000000573694 in os_fsync (fd=36) at ../src/nvim/os/fs.c:631
5 0x0000000000528f5a in mf_sync (mfp=0x7f72d8968d00, flags=5) at ../src/nvim/memfile.c:466
6 0x000000000052d569 in ml_preserve (buf=0x7f72d890f000, message=0) at ../src/nvim/memline.c:1659
7 0x00000000004ebadf in buf_write (buf=<optimized out>, fname=<optimized out>, sfname=<optimized out>, start=1, end=1997, eap=0x7fffc864c570,
append=<optimized out>, forceit=<optimized out>, reset_changed=<optimized out>, filtering=<optimized out>) at ../src/nvim/fileio.c:3071
8 0x00000000004b44ff in do_write (eap=0x7fffc864c570) at ../src/nvim/ex_cmds.c:1745
...
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
closes #7698
Wrapping a command in double-quotes allows cmd.exe to safely dequote the
entire command as if the user entered the entire command in an
interactive prompt. This reduces the need to escape nested and uneven
double quotes.
The `/s` flag of cmd.exe makes the behaviour more reliable:
:set shellcmdflag=/s\ /c
Before this patch, cmd.exe cannot use cygwin echo.exe (as opposed to
cmd.exe `echo` builtin) even if it is wrapped in double quotes.
Example:
:: internal echo
> cmd /s /c " echo foo\:bar" "
foo\:bar"
:: cygwin echo.exe
> cmd /s /c " "echo" foo\:bar" "
foo:bar
|
| |
| |
| |
| | |
Update tests.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Most fonts should have these by now. Both are a significant visual
improvement.
- Vertical connecting bar `│` is used by tmux, pstree, Windows 7 cmd.exe
and nvim-qt.exe.
- Middle dot `·` works on Windows 7 cmd.exe, nvim-qt.exe.
For reference: tmux uses these chars to draw lines: │ ├ ─
|
| |
| |
| |
| |
| |
| |
| |
| | |
Make HlAttr contain highlighting state for both color modes (cterm and rgb).
This allows us to implement termguicolors completely in the TUI.
Simplify some logic duplicated between ui.c and screen.c. Also avoid
some superfluous highlighting reset events.
|
| |
| |
| |
| | |
ref #6289
|
| | |
|
| |
| |
| |
| | |
ref #7520
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
'encoding'
Problem: When running :make the output may be in the system encoding,
different from 'encoding'.
Solution: Add the 'makeencoding' option. (Ken Takata)
https://github.com/vim/vim/commit/2c7292dc5bbf155fe2192d417363b8c085759cad
|
| |
| |
| | |
also make termguicolors mutable after startup
|
| |
| |
| |
| |
| |
| | |
It's an empty string, so there's no reason to try to translate it.
Closes #7717
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The flag enables the current local directory set by ":lcd" to be saved
to views which is the current default behaviour. The option can be
removed to disable this behaviour.
closes #7435
vim-patch:8.0.1289
|
| | |
|
|\ \ |
|
| | |
| | |
| | |
| | |
| | |
| | | |
- default 'titleold' to empty
- set title on exit if 'title' is enabled and 'titleold' is non-empty
- update docs
|
|\ \ \
| | | |
| | | |
| | | |
| | | |
| | | | |
Problem: Value of 'thesaurus' option not checked properly.
Solution: Add P_NDNAME flag. (Daisuke Suzuki)
https://github.com/vim/vim/commit/f422bcc7f9615fe91fa69b059cfe4785093d3d4a
|
| |/ /
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Some options are not strictly checked.
Solution: Add flags for strickter checks.
https://github.com/vim/vim/commit/031cb743ae154cfb727a9b7787bdcb61202ff1c8
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Cannot set 'dictionary' to a path.
Solution: Allow for slash and backslash. Add a test (partly by Daisuke
Suzuki, closes vim/vim#1279, closes vim/vim#1284)
https://github.com/vim/vim/commit/7554da4033498c4da0af3cde542c3e87e9097b73
|
|/ /
| |
| |
| |
| |
| |
| | |
Problem: Some options are not strictly checked.
Solution: Add flags for strickter checks.
https://github.com/vim/vim/commit/031cb743ae154cfb727a9b7787bdcb61202ff1c8
|
| |
| |
| |
| |
| | |
This gives libtermkey 50msec to reassemble split multibyte sequences
like DCSes.
|
| | |
|
| | |
|
| |
| |
| |
| | |
Closes #6577
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Calling cmd.exe in Windows follows a very different pattern from Vim.
The primary difference is that Vim does a nested call to cmd.exe, e.g.
the following call in Vim
system('echo a 2>&1')
spawns the following processes
"C:\Program Files (x86)\Vim\vim80\vimrun" -s C:\Windows\system32\cmd.exe /c (echo a 2^>^&1
^>C:\Users\dummy\AppData\Local\Temp\VIoC169.tmp 2^>^&1)
C:\Windows\system32\cmd.exe /c C:\Windows\system32\cmd.exe /c (echo a 2^>^&1
^>C:\Users\dummy\AppData\Local\Temp\VIo3C6C.tmp 2^>^&1)
C:\Windows\system32\cmd.exe /c (echo a 2>&1
>C:\Users\dummy\AppData\Local\Temp\VIo3C6C.tmp 2>&1)
The escaping with ^ is needed because cmd.exe calls itself and needs to
preserve the special metacharacters for the last call. However in nvim
no nested call is made, system('') spawns a single cmd.exe process.
Setting shellxescape to "" disables escaping with ^.
The previous default for shellxquote=( wrapped any command in
parenthesis, in Vim this is more meaningful due to the use of tempfiles
to store the output and redirection (also see &shellquote). There is
a slight benefit in having the default be empty because some expressions
that run in console will not run within parens e.g. due to unbalanced
double quotes
system('echo "a b')
|
|/ |
|
| |
|
|
|
|
| |
Also: update default 'guicursor' to match the documentation.
|
|
|
|
|
|
|
|
|
|
| |
Problem: The 'langnoremap' option leads to double negatives. And it does
not work for the last character of a mapping.
Solution: Add 'langremap' with the opposite value. Keep 'langnoremap' for
backwards compatibility. Make it work for the last character of a
mapping. Make the test work.
https://github.com/vim/vim/commit/920694c1b60fac8017b8909efcc24f189804a9bb
|
|
|
|
|
|
|
|
|
|
|
| |
Make the 'scrollback' option work like most other buffer-local options:
- `:set scrollback=x` sets the global and local value
- `:setglobal scrollback=x` sets only the global default
- new terminal buffers inherit the global
Normal buffers are still always -1, and :setlocal there is an error.
Closes #6337
|
|
|
|
|
|
|
|
| |
Problem: 'formatprg' is a global option but the value may depend on the
type of buffer. (Sung Pae)
Solution: Make 'formatprg' global-local. (closes vim/vim#1380)
https://github.com/vim/vim/commit/9be7c04e6cd5b0facedcb56b09a5bcfc339efe03
|
|
|
|
|
|
|
|
|
|
|
| |
- Vim "unix default" of 'noshowcmd' is serving few users. And it's
inconsistent.
- 'ruler' and 'belloff=all' improve the out-of-the-box experience.
- Continue to use 'noshowcmd' and 'noruler' by default in the functional
tests to keep them fast.
TODO: Add a "disable slow stuff" command or mapping to address the
use-case of a very slow terminal connection.
|
|
|
|
| |
Closes #2637
|
| |
|
|
|
| |
This was never supported and it does not make sense for Nvim.
|
|
|
|
|
|
|
|
|
|
| |
This default causes too much confusion for terminal users. Until
a better approach is implemented, revert to the traditional default.
Better solution would be:
- Implement a right-click menu for TUI
- Set 'mouse=a' *only* if clipboard is working.
Closes #5938
|
|
|
|
|
|
|
| |
Problem: Setting 'cursorline' changes the curswant column. (Daniel Hahler)
Solution: Add the P_RWINONLY flag. (closes vim/vim#1297)
https://github.com/vim/vim/commit/a2477fd3490c1166522631eee53c57d34321086a
|
|
|
|
|
|
|
| |
Problem: The sign column disappears when the last sign is deleted.
Solution: Add the 'signcolumn' option. (Christian Brabandt)
https://github.com/vim/vim/commit/95ec9d6a6ab3117d60ff638670a803d43974ba51
|
|
|
|
|
|
|
|
|
| |
'inccommand' allows us to expand the feature to other commands, such as:
:cdo
:cfdo
:global
Also rename "IncSubstitute" highlight group to "Substitute".
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Originally implemented by
* Clement0
* DesbyP
* aym7
* Adrey06
* Robinhola
in #4811. Major reworkings and bug
fixes by
* bfredl
Most tests suggested by ZyX-l, suggestions for improvements by oni-link.
|
|
|
|
|
|
|
|
|
| |
Problem: Although emoji characters are ambiguous width, best is to treat
them as full width.
Solution: Update the Unicode character tables. Add the 'emoji' options.
(Yasuhiro Matsumoto)
https://github.com/vim/vim/commit/3848e00e0177abdb31bc600234967863ec487233
|