2015-01-30 05:19:43 -07:00
|
|
|
*vim_diff.txt* For Nvim. {Nvim}
|
|
|
|
|
|
|
|
|
|
|
|
NVIM REFERENCE MANUAL
|
|
|
|
|
|
|
|
|
|
|
|
Differences between Nvim and Vim *vim-differences*
|
|
|
|
|
|
|
|
Throughout the help files, differences between Nvim and Vim are indicated via
|
|
|
|
the "{Nvim}" tag. This document is a complete and centralized list of all
|
|
|
|
these differences.
|
|
|
|
|
|
|
|
1. Configuration |nvim-configuration|
|
|
|
|
2. Option defaults |nvim-option-defaults|
|
|
|
|
3. Changed features |nvim-features-changed|
|
|
|
|
4. New features |nvim-features-new|
|
|
|
|
5. Missing legacy features |nvim-features-missing|
|
|
|
|
6. Removed features |nvim-features-removed|
|
|
|
|
|
|
|
|
|
|
|
|
==============================================================================
|
|
|
|
1. Configuration *nvim-configuration*
|
|
|
|
|
2015-10-17 07:25:53 -07:00
|
|
|
- Use `$XDG_CONFIG_HOME/nvim/init.vim` instead of `.vimrc` for storing
|
|
|
|
configuration.
|
|
|
|
- Use `$XDG_CONFIG_HOME/nvim` instead of `.vim` to store configuration files.
|
2015-11-14 11:50:45 -07:00
|
|
|
- Use `$XDG_DATA_HOME/nvim/shada/main.shada` instead of `.viminfo` for persistent
|
2015-10-17 07:25:53 -07:00
|
|
|
session information.
|
2015-01-30 05:19:43 -07:00
|
|
|
|
|
|
|
==============================================================================
|
|
|
|
2. Option defaults *nvim-option-defaults*
|
|
|
|
|
2015-07-14 04:53:45 -07:00
|
|
|
- 'autoindent' is set by default
|
2015-06-20 12:39:40 -07:00
|
|
|
- 'autoread' is set by default
|
2015-05-12 16:49:24 -07:00
|
|
|
- 'backspace' defaults to "indent,eol,start"
|
2015-06-18 13:11:51 -07:00
|
|
|
- 'complete' doesn't include "i"
|
2015-06-20 10:17:26 -07:00
|
|
|
- 'display' defaults to "lastline"
|
2015-01-30 05:19:43 -07:00
|
|
|
- 'encoding' defaults to "utf-8"
|
2015-05-15 22:23:16 -07:00
|
|
|
- 'formatoptions' defaults to "tcqj"
|
2015-06-20 11:59:25 -07:00
|
|
|
- 'history' defaults to 10000 (the maximum)
|
2015-06-20 13:40:03 -07:00
|
|
|
- 'hlsearch' is set by default
|
2015-06-18 19:02:36 -07:00
|
|
|
- 'incsearch' is set by default
|
2015-06-18 12:56:39 -07:00
|
|
|
- 'langnoremap' is set by default
|
2015-06-20 14:45:03 -07:00
|
|
|
- 'laststatus' defaults to 2 (statusline is always shown)
|
2015-06-20 13:16:10 -07:00
|
|
|
- 'listchars' defaults to "tab:> ,trail:-,nbsp:+"
|
2015-06-18 20:37:11 -07:00
|
|
|
- 'mouse' defaults to "a"
|
2015-05-12 16:49:24 -07:00
|
|
|
- 'nocompatible' is always set
|
2015-05-15 22:07:56 -07:00
|
|
|
- 'nrformats' defaults to "hex"
|
2015-06-20 12:39:40 -07:00
|
|
|
- 'sessionoptions' doesn't include "options"
|
2015-06-18 13:23:29 -07:00
|
|
|
- 'smarttab' is set by default
|
2015-06-20 12:10:29 -07:00
|
|
|
- 'tabpagemax' defaults to 50
|
2015-05-15 22:33:26 -07:00
|
|
|
- 'tags' defaults to "./tags;,tags"
|
2015-05-12 16:49:24 -07:00
|
|
|
- 'ttyfast' is always set
|
2015-06-20 12:23:38 -07:00
|
|
|
- 'viminfo' includes "!"
|
2015-05-16 11:09:40 -07:00
|
|
|
- 'wildmenu' is set by default
|
2015-01-30 05:19:43 -07:00
|
|
|
|
|
|
|
==============================================================================
|
|
|
|
3. Changed features *nvim-features-changed*
|
|
|
|
|
|
|
|
Nvim always builds with all features, in contrast to Vim which may have
|
|
|
|
certain features removed/added at compile-time. This is like if Vim's "HUGE"
|
|
|
|
build was the only Vim release type (except Nvim is smaller than Vim's "HUGE"
|
|
|
|
build).
|
|
|
|
|
|
|
|
If a Python interpreter is available on your `$PATH`, |:python| and |:python3|
|
|
|
|
are always available and may be used simultaneously in separate plugins. The
|
|
|
|
`neovim` pip package must be installed to use Python plugins in Nvim (see
|
|
|
|
|nvim-python|).
|
|
|
|
|
2015-07-18 02:23:42 -07:00
|
|
|
|mkdir()| behaviour changed:
|
|
|
|
1. Assuming /tmp/foo does not exist and /tmp can be written to
|
|
|
|
mkdir('/tmp/foo/bar', 'p', 0700) will create both /tmp/foo and /tmp/foo/bar
|
|
|
|
with 0700 permissions. Vim mkdir will create /tmp/foo with 0755.
|
|
|
|
2. If you try to create an existing directory with `'p'` (e.g. mkdir('/',
|
|
|
|
'p')) mkdir() will silently exit. In Vim this was an error.
|
|
|
|
3. mkdir() error messages now include strerror() text when mkdir fails.
|
|
|
|
|
2015-08-29 07:13:39 -07:00
|
|
|
'encoding' cannot be changed after startup.
|
|
|
|
|
2015-09-20 08:04:33 -07:00
|
|
|
|string()| and |:echo| behaviour changed:
|
|
|
|
1. No maximum recursion depth limit is applied to nested container
|
|
|
|
structures.
|
|
|
|
2. |string()| fails immediately on nested containers, not when recursion limit
|
|
|
|
was exceeded.
|
|
|
|
2. When |:echo| encounters duplicate containers like >
|
|
|
|
|
|
|
|
let l = []
|
|
|
|
echo [l, l]
|
|
|
|
<
|
|
|
|
it does not use "[...]" (was: "[[], [...]]", now: "[[], []]"). "..." is
|
|
|
|
only used for recursive containers.
|
|
|
|
3. |:echo| printing nested containers adds "@level" after "..." designating
|
|
|
|
the level at which recursive container was printed: |:echo-self-refer|.
|
|
|
|
Same thing applies to |string()| (though it uses construct like
|
|
|
|
"{E724@level}"), but this is not reliable because |string()| continues to
|
|
|
|
error out.
|
|
|
|
|
2015-07-05 04:08:50 -07:00
|
|
|
Viminfo text files were replaced with binary (messagepack) ShaDa files.
|
|
|
|
Additional differences:
|
|
|
|
|
|
|
|
- |shada-c| has no effect.
|
|
|
|
- |shada-s| now limits size of every item and not just registers.
|
2015-08-15 04:50:04 -07:00
|
|
|
- When reading ShaDa files items are merged according to the timestamp.
|
|
|
|
|shada-merging|
|
2015-07-05 16:26:44 -07:00
|
|
|
- 'viminfo' option got renamed to 'shada'. Old option is kept as an alias for
|
|
|
|
compatibility reasons.
|
2015-08-15 04:50:04 -07:00
|
|
|
- |:wviminfo| was renamed to |:wshada|, |:rviminfo| to |:rshada|. Old
|
|
|
|
commands are still kept.
|
2015-11-05 16:50:18 -07:00
|
|
|
- |:oldfiles| supports !.
|
2015-08-15 04:50:04 -07:00
|
|
|
- When writing (|:wshada| without bang or at exit) it merges much more data,
|
|
|
|
and does this according to the timestamp. Vim merges only marks.
|
|
|
|
|shada-merging|
|
2015-07-26 11:02:56 -07:00
|
|
|
- ShaDa file format was designed with forward and backward compatibility in
|
|
|
|
mind. |shada-compatibility|
|
2015-08-15 04:50:04 -07:00
|
|
|
- Some errors make ShaDa code keep temporary file in-place for user to decide
|
|
|
|
what to do with it. Vim deletes temporary file in these cases.
|
|
|
|
|shada-error-handling|
|
|
|
|
- Vim keeps no timestamps at all, neither in viminfo file nor in the instance
|
|
|
|
itself.
|
2015-11-01 11:26:53 -07:00
|
|
|
- ShaDa file keeps search direction (|v:searchforward|), viminfo does not.
|
2015-07-05 04:08:50 -07:00
|
|
|
|
2015-01-30 05:19:43 -07:00
|
|
|
==============================================================================
|
|
|
|
4. New Features *nvim-features-new*
|
|
|
|
|
|
|
|
See |nvim-intro| for a list of Nvim's largest new features.
|
|
|
|
|
2015-07-17 06:04:23 -07:00
|
|
|
|bracketed-paste-mode| is built-in and enabled by default.
|
|
|
|
|
2015-06-23 21:42:33 -07:00
|
|
|
Meta (alt) chords are recognized (even in the terminal).
|
2015-04-24 16:10:59 -07:00
|
|
|
<M-1>, <M-2>, ...
|
|
|
|
<M-BS>, <M-Del>, <M-Ins>, ...
|
|
|
|
<M-/>, <M-\>, ...
|
|
|
|
<M-Space>, <M-Enter>, <M-=>, <M-->, <M-?>, <M-$>, ...
|
2015-01-30 05:19:43 -07:00
|
|
|
|
2015-06-23 21:42:33 -07:00
|
|
|
Note: Meta chords are case-sensitive (<M-a> is distinguished from <M-A>).
|
|
|
|
|
|
|
|
Some `CTRL-SHIFT-...` key chords are distinguished from `CTRL-...` variants (even in
|
|
|
|
the terminal). Specifically, the following are known to work:
|
2015-04-24 16:10:59 -07:00
|
|
|
<C-Tab>, <C-S-Tab>
|
|
|
|
<C-BS>, <C-S-BS>
|
|
|
|
<C-Enter>, <C-S-Enter>
|
2015-01-30 05:19:43 -07:00
|
|
|
|
|
|
|
Events:
|
2015-04-24 16:10:59 -07:00
|
|
|
|TabNew|
|
|
|
|
|TabNewEntered|
|
|
|
|
|TabClosed|
|
2015-11-10 20:27:50 -07:00
|
|
|
|TermOpen|
|
|
|
|
|TermClose|
|
2015-01-30 05:19:43 -07:00
|
|
|
|
|
|
|
Highlight groups:
|
2015-04-24 16:10:59 -07:00
|
|
|
|hl-EndOfBuffer|
|
|
|
|
|hl-TermCursor|
|
|
|
|
|hl-TermCursorNC|
|
2015-01-30 05:19:43 -07:00
|
|
|
|
|
|
|
==============================================================================
|
|
|
|
5. Missing legacy features *nvim-features-missing*
|
2015-06-24 17:22:56 -07:00
|
|
|
*if_ruby* *if_lua* *if_perl* *if_mzscheme* *if_tcl*
|
2015-01-30 05:19:43 -07:00
|
|
|
|
|
|
|
These legacy Vim features may be implemented in the future, but they are not
|
|
|
|
planned for the current milestone.
|
|
|
|
|
|
|
|
- vim.bindeval() (new feature in Vim 7.4 Python interface)
|
2015-06-24 17:22:56 -07:00
|
|
|
- |if_ruby|
|
|
|
|
- |if_lua|
|
|
|
|
- |if_perl|
|
|
|
|
- |if_mzscheme|
|
|
|
|
- |if_tcl|
|
2015-01-30 05:19:43 -07:00
|
|
|
|
|
|
|
==============================================================================
|
|
|
|
6. Removed features *nvim-features-removed*
|
|
|
|
|
|
|
|
These features are in Vim, but have been intentionally removed from Nvim.
|
|
|
|
|
2015-04-24 16:10:59 -07:00
|
|
|
Vi-compatible mode:
|
|
|
|
":set nocompatible" is ignored
|
|
|
|
":set compatible" is an error
|
2015-01-30 05:19:43 -07:00
|
|
|
|
2015-04-24 16:10:59 -07:00
|
|
|
Ed-compatible mode:
|
|
|
|
":set noedcompatible" is ignored
|
|
|
|
":set edcompatible" is an error
|
2015-01-30 05:19:43 -07:00
|
|
|
|
2015-04-24 16:10:59 -07:00
|
|
|
'ttyfast':
|
|
|
|
":set ttyfast" is ignored
|
|
|
|
":set nottyfast" is an error
|
2015-01-30 05:19:43 -07:00
|
|
|
|
2015-04-24 16:10:59 -07:00
|
|
|
Encryption support:
|
|
|
|
'cryptmethod'
|
|
|
|
'key'
|
2015-01-30 05:19:43 -07:00
|
|
|
|
2015-04-24 16:10:59 -07:00
|
|
|
MS-DOS support:
|
|
|
|
'bioskey'
|
|
|
|
'conskey'
|
2015-01-30 05:19:43 -07:00
|
|
|
|
2015-06-26 09:27:42 -07:00
|
|
|
Highlight groups:
|
|
|
|
|hl-VisualNOS|
|
|
|
|
|
2015-04-24 16:10:59 -07:00
|
|
|
Other options:
|
2015-11-24 14:46:52 -07:00
|
|
|
'antialias'
|
2015-07-03 02:33:48 -07:00
|
|
|
'cpoptions' ('g', 'w', 'H', '*', '-', 'j', and all POSIX flags were removed)
|
2015-07-15 19:45:14 -07:00
|
|
|
'guioptions' (only the 't' flag was removed)
|
2015-06-25 21:57:22 -07:00
|
|
|
'guipty'
|
2015-05-07 08:20:38 -07:00
|
|
|
'macatsui'
|
2015-04-24 16:10:59 -07:00
|
|
|
'shelltype'
|
2015-05-05 19:00:43 -07:00
|
|
|
'shortname'
|
2015-01-14 00:02:39 -07:00
|
|
|
'termencoding' (Vim 7.4.852 also removed this for Windows)
|
2015-04-24 16:10:59 -07:00
|
|
|
'textauto'
|
|
|
|
'textmode'
|
2015-09-17 08:19:46 -07:00
|
|
|
'toolbar'
|
|
|
|
'toolbariconsize'
|
2015-05-05 19:00:43 -07:00
|
|
|
'ttybuiltin'
|
2015-05-05 19:00:43 -07:00
|
|
|
'ttymouse'
|
2015-05-05 19:00:43 -07:00
|
|
|
'weirdinvert'
|
2015-01-30 05:19:43 -07:00
|
|
|
|
2015-04-24 16:10:59 -07:00
|
|
|
Other commands:
|
2015-07-19 03:14:26 -07:00
|
|
|
:Print
|
2015-04-24 16:10:59 -07:00
|
|
|
:fixdel
|
2015-07-14 04:53:45 -07:00
|
|
|
:mode (no longer accepts an argument)
|
2015-10-30 11:35:12 -07:00
|
|
|
:open
|
2015-04-24 16:10:59 -07:00
|
|
|
:shell
|
2015-07-14 04:53:45 -07:00
|
|
|
:tearoff
|
2015-01-30 05:19:43 -07:00
|
|
|
|
2015-04-24 16:10:59 -07:00
|
|
|
Other compile-time features:
|
|
|
|
EBCDIC
|
2015-05-15 22:33:26 -07:00
|
|
|
Emacs tags support
|
2015-11-09 23:45:03 -07:00
|
|
|
X11 integration (see |x11-selection|)
|
2015-01-30 05:19:43 -07:00
|
|
|
|
2015-05-07 08:20:38 -07:00
|
|
|
Nvim does not have a built-in GUI and hence the following aliases have been
|
|
|
|
removed: gvim, gex, gview, rgvim, rgview
|
|
|
|
|
2015-01-30 05:19:43 -07:00
|
|
|
"Easy mode" (eview, evim, nvim -y)
|
2015-04-24 16:10:59 -07:00
|
|
|
"(g)vimdiff" (alias for "(g)nvim -d" |diff-mode|)
|
2015-01-30 05:19:43 -07:00
|
|
|
"Vi mode" (nvim -v)
|
|
|
|
|
|
|
|
The ability to start nvim via the following aliases has been removed in favor
|
|
|
|
of just using their command line arguments:
|
|
|
|
|
|
|
|
ex nvim -e
|
|
|
|
exim nvim -E
|
|
|
|
view nvim -R
|
|
|
|
rvim nvim -Z
|
|
|
|
rview nvim -RZ
|
|
|
|
|
|
|
|
==============================================================================
|
|
|
|
vim:tw=78:ts=8:noet:ft=help:norl:
|