Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
588 lines (426 sloc) 21.9 KB
*neovintageous.txt* Neovintageous
NEOVINTAGEOUS - main help file
Jump to a subject: Position the cursor on a tag (e.g. |bars|) and hit CTRL-].
Jump back: Type CTRL-I or CTRL-O. Repeat to go further back.
NeoVintageous *neovintageous* *nv*
1. Command Palette |nv-command-palette|
2. Multiple cursors |nv-multiple-cursors|
3. Opening a view |nv-opening-view|
4. neovintageousrc |nv-rc|
5. Plugins |nv-plugins|
1.1 Abolish |nv-abolish|
1.2 Commentary |nv-commentary|
1.3 HighlightedYank |nv-highlightedyank|
1.4 Surround |nv-surround|
1.5 Unimpaired |nv-unimpaired|
1.6 Indent Object |nv-indent-object|
6. Options |nv-options|
7. Settings |nv-settings|
8. Search highlighting |nv-search-highlighting|
9. Jumping to diffs |nv-jumpto-diffs|
10. Toggle Command |nv-toggle|
Note that Vim feature-parity is an ongoing effort, not all features are
implemented and differences are not fully documented. The Vim documentation is
provided in full without modification alongside this help document.
Please don't hesitate to open an issue about new features, enhancements, and
usage. If you are new to Vim also see |help.txt|.
==============================================================================
COMMAND PALETTE *nv-command-palette*
NeoVintageous: Changelog Open CHANGELOG.
NeoVintageous: Open RC File Open runtime configuration file.
NeoVintageous: Reload RC File Reload the runtime configuration file.
NeoVintageous: Toggle CTRL keys Turn CTRL key bindings on and off.
NeoVintageous: Toggle SUPER keys Turn SUPER key bindings on and off.
==============================================================================
MULTIPLE CURSORS *nv-multiple-cursors*
normal mode / visual mode
start: <C-n> or gh Start multiple cursor.
next: <C-n> or j Add next match.
skip: <C-x> or l Skip next match.
prev: <C-p> or k Remove current match.
all: <M-n> or A Select all matches.
You can now use visual commands e.g. c, I, x, y work without any issues.
You could also go to normal mode by pressing v and use normal commands there,
for example commands like ciw work without any issues.
At any time you can press <Esc> or J to exit back to regular Vim. To change
the behaviour of exiting see 'vintageous_multi_cursor_exit_from_visual_mode'.
<C-n> or gh Start multiple cursor.
<C-n> or j Add next match.
<C-x> or l Skip next match.
<C-p> or k Remove current match and go back on previous.
<Esc> or J Quit and enter normal mode.
<M-n> or A Select all matches.
v Enter normal mode.
gH Select all search occurrences (/, ?, *, #).
==============================================================================
OPENING A VIEW *nv-opening-view*
Some windowing commands require the Origami package.
See: https://packagecontrol.io/packages/Origami.
CTRL-W CTRL-S
CTRL-W s
CTRL-W S
:sp[lit] [file] Split current window in two. The result is two views
on the same file. See |CTRL-W_s| for more details.
CTRL-W CTRL-V
CTRL-W v
CTRL-W V
:vs[plit] [file] Like |:split|, but split vertically. See |CTRL-W_v|.
==============================================================================
NEOVINTAGEOUSRC *nv-rc* *vintageousrc* *neovintageousrc*
A file that contains initialization commands is generically called a "vimrc"
or config file. In NeoVintageous it's called a "neovintageousrc" file. Each
line in a neovintageousrc file is executed as an Ex command line.
The neovintageousrc file can be opened and reloaded via the Command Palette.
The |mapleader| variable is supported, for example: >
let mapleader=,
The |set| command is partially supported. The following are currently
implemented (see |nv-options| for a list of currently supported options):
:se[t] {option}? Show value of {option}.
:se[t] {option} Toggle option: set, switch it on.
Number option: show value.
String option: show value.
:se[t] no{option} Toggle option: Reset, switch it off.
:se[t] {option}! Toggle option: Invert value.
The following |:map-commands| are supported:
:noremap {lhs} {rhs} |:noremap|
:nnoremap {lhs} {rhs} |:nnoremap|
:onoremap {lhs} {rhs} |:onoremap|
:snoremap {lhs} {rhs} |:snoremap|
:vnoremap {lhs} {rhs} |:vnoremap|
Use <CR> to indicate pressing enter when mapping commands: >
noremap <C-s> :w<CR>
Basic leading and trailing sequences in mappings is supported: >
nnoremap <leader>sp vip:sort u<CR>
To map Sublime Text commands you need to format the command name as MixedCase.
The command name is converted to snake_case before being executed by Sublime
Text and basic arguments in the form "key=value" are accepted, for example: >
nnoremap <leader>i :GotoSymbolInProject<CR>
nnoremap <leader>f :ShowOverlay overlay=goto text=@<CR>
Super-keys can be mapped by the `<D-...>` special keys (super-keys are
disabled by default, see |nv-settings| for details on enabling them): >
nnoremap <D-i> :GotoSymbolInProject<CR>
Here is an example neovintageous file: >
set ignorecase
set winaltkeys=menu
let mapleader=,
nnoremap <leader><bar> <C-w><bar>
nnoremap <leader>= <C-w>=
nnoremap <leader>_ <C-w>_
nnoremap <leader>d :Neovintageous action=toggle_side_bar<CR>
nnoremap <leader>en :Neovintageous action=open_rc_file<CR>
nnoremap <leader>f :ShowOverlay overlay=goto text=@<CR>
nnoremap <leader>hu :RevertModification<CR>
nnoremap <leader>o :ls<CR>
nnoremap <leader>q gqip:w<CR>
nnoremap <leader>r :reg<CR>
nnoremap <D-i> :GotoSymbolInProject<CR>
noremap <C-l> :nohlsearch<CR>
noremap <C-s> :w<CR>
noremap <space> :
noremap <leader>y "+y
noremap <leader>Y "+Y
noremap <leader>p "+p
noremap <leader>P "+P
nnoremap <leader>s) vi):sort u<CR>
nnoremap <leader>s] vi]:sort u<CR>
nnoremap <leader>si vii:sort u<CR>
nnoremap <leader>sp vip:sort u<CR>
nnoremap <leader>ss vip:sort u<CR>
vnoremap <leader>s :sort u<CR>
To enable toggling the side bar when the side bar has focus add the following
key binding, Goto Menu > Preferences > Key Bindings: >
[
{
"keys": [",", "d"],
"command": "neovintageous",
"args": { "action": "toggle_side_bar" },
"context": [ { "key": "control", "operand": "sidebar_tree" } ]
}
]
==============================================================================
PLUGINS *nv-plugins* *plugins*
Note that plugin feature-parity is an ongoing effort, features of the original
plugin may not be implemented fully and differences may not be documented. The
original plugin documentation is provided in full without modification.
Please don't hesitate to open an issue about new features, enhancements, and
usage. If you are new to Vim also see |help.txt|.
------------------------------------------------------------------------------
ABOLISH *nv-abolish* *abolish*
Abolish is a port of vim-abolish.
Tim Pope describes it as "three superficially unrelated plugins in one that
share a common theme: working with variants of a word."
Note that currently only the "case mutating algorithms" are supported.
See |abolish.txt| and https://github.com/tpope/vim-abolish.
------------------------------------------------------------------------------
COMMENTARY *nv-commentary* *commentary*
Commentary is a port of vim-commentary.
It adds commands that make it easier to comment, uncomment, and toggle comments.
See |commentary.txt| and https://github.com/tpope/vim-commentary.
------------------------------------------------------------------------------
HIGHLIGHTEDYANK *nv-highlightedyank* *highlightedyank*
Highlighted Yank is a port of vim-highlightedyank.
This plugin highlights a yanked region immediately after being yanked. The
duration and style is configurable.
When new text is yanked, the old highlighting is deleted. Or when former lines
are edited, the highlighting is deleted to prevent shifting the position, also.
The highlighted duration can be configured by the 'highlightedyank_duration'
setting and the style can be configured by the 'highlightedyank_style' setting.
To customise the colors, create a color scheme override for your color scheme:
for example if you have the default Monokai color scheme enabled, create a file
named `Monokai.sublime-color-scheme` in the User directory (find the User
directory location via the Menu: `Preferences > Browse Packages...`), then
create the styles using the scopes: >
To customise the colors, create a color scheme override: for example if you
have the default Monokai color scheme enabled - create a file named
Monokai.sublime-color-scheme in the Sublime Text User directory
(Menu > Preferences > BrowsePackages...), and create the styles using the
"highlightedyank" scope: >
{
"rules":
[
{
"scope": "highlightedyank",
"background": "#e6db74",
"foreground": "#272822"
}
]
}
See: https://github.com/machakann/vim-highlightedyank
------------------------------------------------------------------------------
SURROUND *nv-surround* *surround*
Surround is a port of vim-surround.
See |surround.txt| and https://github.com/tpope/vim-surround.
------------------------------------------------------------------------------
UNIMPAIRED *nv-unimpaired* *unimpaired*
Unimpaired is a port of vim-unimpaired.
NEXT AND PREVIOUS
[b |:bprevious|
]b |:bnext|
[B |:bfirst|
]B |:blast|
[t |:tprevious|
]t |:tnext|
[T |:tfirst|
]T |:tlast|
[l Jump to the [count] previous error.
]l Jump to the [count] next error.
The jump to error commands require SublimeLinter.
LINE OPERATIONS
[<Space> Add [count] blank lines above the cursor.
]<Space> Add [count] blank lines below the cursor.
[e Exchange the current line with [count] lines above it.
]e Exchange the current line with [count] lines below it.
[n Go to the previous SCM conflict marker.
]n Go to the next SCM conflict marker.
OPTION TOGGLING
On Off Toggle Option
*[oa* *]oa* *yoa* 'menu'
*[oc* *]oc* *yoc* 'cursorline'
*[oe* *]oe* *yoe* 'statusbar'
*[oh* *]oh* *yoh* 'hlsearch'
*[oi* *]oi* *yoi* 'ignorecase'
*[ol* *]ol* *yol* 'list'
*[om* *]om* *yom* 'minimap'
*[on* *]on* *yon* 'number'
*[os* *]os* *yos* 'spell'
*[ot* *]ot* *yot* 'sidebar'
*[ow* *]ow* *yow* 'wrap'
See |unimpaired.txt| and https://github.com/tpope/vim-unimpaired.
------------------------------------------------------------------------------
INDENT OBJECT *nv-indent-object* *indent-object*
Indent Object is a port of vim-indent-object.
See |indent-object.txt| and https://github.com/michaeljsmith/vim-indent-object
==============================================================================
OPTIONS *nv-options*
List of currently supported options:
'autoindent' 'belloff' 'expandtabs' 'hlsearch' 'ignorecase' 'incsearch'
'list' 'magic' 'menu' 'minimap' 'modeline' 'modelines' 'number' 'shell'
'sidebar' 'smartcase' 'spell' 'statusbar' 'tabstop' 'textwidth'
'winaltkeys' 'wrap' 'wrapscan'
See `:help '{option}'` for help on individual options.
==============================================================================
SETTINGS *nv-settings*
To edit settings go to `Menu > Preferences > Settings` or use the Command
Palette: press `Ctrl+Shift+P` and select the "Preferences: Settings" command.
List of available settings:
*'highlightedyank'*
'highlightedyank' boolean (default on)
Enable or disable the HighlightedYank plugin.
*'highlightedyank_duration'*
'highlightedyank_duration'
number (default 1000)
Assign number of time in milliseconds.
*'highlightedyank_style'*
'highlightedyank_style' string (default fill)
Valid values: fill, outline, underline, squiggly_underline,
stippled_underline.
*'neovintageous_search_cur_style'*
'neovintageous_search_cur_style'
string (default fill)
The current search style. Valid values: fill, outline, underline,
squiggly_underline, stippled_underline.
*'neovintageous_search_inc_style'*
'neovintageous_search_inc_style'
string (default fill)
The incremental search style. Valid values: fill, outline, underline,
squiggly_underline, stippled_underline.
*'neovintageous_search_occ_style'*
'neovintageous_search_occ_style'
string (default fill)
The search occurrences style. Valid values: fill, outline, underline,
squiggly_underline, stippled_underline.
*'vintageous_bell'*
'vintageous_bell' string (default "blink")
Visual bell style type. Valid values are: blink, view, or views.
*'vintageous_bell_color_scheme'*
'vintageous_bell_color_scheme'
string (default "dark")
Visual bell color scheme. Valid values are: "dark", "light", or color
scheme path. The color scheme path should be in the format:
Packages/Name/name.hidden-color-scheme
*'vintageous_default_mode'*
'vintageous_default_mode'
string (default "")
The default mode to use when activating or switching views.
Valid values are: "insert" or "".
mode | description
------ | -----------
insert | Enter insert mode when opening or switching views or when
the window receives focus and is not in visual mode i.e. visual
mode selections are retained when the window loses focus.
*'vintageous_enable_abolish'*
'vintageous_enable_abolish'
boolean (default on)
Plugin: A port of https://github.com/tpope/vim-abolish.
*'vintageous_enable_commentary'*
'vintageous_enable_commentary'
boolean (default on)
Plugin: A port of https://github.com/tpope/vim-commentary.
*'vintageous_enable_multiple_cursors'*
'vintageous_enable_multiple_cursors'
boolean (default on)
Plugin: A port of https://github.com/terryma/vim-multiple-cursors.
*'vintageous_enable_sublime'*
'vintageous_enable_sublime'
boolean (default on)
Plugin: Supports specific Sublime Text enhancements and tweaks.
*'vintageous_enable_surround'*
'vintageous_enable_surround'
boolean (default on)
Plugin: A port of https://github.com/tpope/vim-surround.
*'vintageous_enable_unimpaired'*
'vintageous_enable_unimpaired'
boolean (default on)
Plugin: A port of https://github.com/tpope/vim-unimpaired.
*'vintageous_multi_cursor_exit_from_visual_mode'*
'vintageous_multi_cursor_exit_from_visual_mode'
boolean (default off)
If set to false, then pressing the quit key (<Esc> or J) in Visual
mode will not quit and delete all existing cursors. Useful if you want
to go back to Normal mode, and still be able to operate on all the
cursors.
*'vintageous_reset_mode_when_switching_tabs'*
'vintageous_reset_mode_when_switching_tabs'
boolean (default on)
Reset to normal mode when a view is activated.
*'vintageous_shell_silent'*
'vintageous_shell_silent'
boolean (default off)
Show output panel from shell commands.
*'vintageous_use_ctrl_keys'*
'vintageous_use_ctrl_keys'
boolean (default: false)
Enable key bindings prefaced by the ctrl-key.
*'vintageous_use_super_keys'*
'vintageous_use_super_keys'
boolean (default off)
Enable key bindings prefaced by the super-key, otherwise known as the
command-key in OSX, and as the windows-key in Windows.
*'vintageous_use_sys_clipboard'*
'vintageous_use_sys_clipboard'
boolean (default off)
Propagate copy actions to the system clipboard.
------------------------------------------------------------------------------
Mapping capslock to escape *nv-capslock*
Neovintageous cannot remap the CapsLock, however it can be remapped at an OS
level e.g. in Ubuntu you can remap the CapsLock to Escape at the terminal: >
gsettings set org.gnome.desktop.input-sources xkb-options "['caps:escape']"
------------------------------------------------------------------------------
Holding down a key like j does not repeat the command *nv-j*
This is a feature of OS X Lion and newer versions. To make a key repeat a
command when holding it down, run this once at the terminal: >
defaults write com.sublimetext.3 ApplePressAndHoldEnabled -bool false
------------------------------------------------------------------------------
Mapping jj or jk to Esc *nv-escape*
`Menu > Preferences > Key Bindings`
jj -> Esc: >
{
"keys": ["j", "j"],
"command": "_enter_normal_mode",
"args": {"mode": "mode_insert"},
"context": [{"key": "vi_insert_mode_aware"}]
}
jk -> Esc: >
{
"keys": ["j", "k"],
"command": "_enter_normal_mode",
"args": {"mode": "mode_insert"},
"context": [{"key": "vi_insert_mode_aware"}]
}
==============================================================================
SEARCH HIGHLIGHTING *nv-search-highlighting*
Search highlighting can be customized. The styles can be configured via
the following settings: >
// Current search style.
// Valid values are: fill, outline, underline, squiggly_underline,
// stippled_underline.
"neovintageous_search_cur_style": "fill",
// Incremental search style.
// Valid values are: fill, outline, underline, squiggly_underline,
// stippled_underline.
"neovintageous_search_inc_style": "fill",
// Search occurences style.
// Valid values are: fill, outline, underline, squiggly_underline,
// stippled_underline.
"neovintageous_search_occ_style": "fill",
Configure settings via `Menu > Preferences > Settings`.
To customise the colors of the styles create a color scheme override. For
example if you're using the "Monokai" color scheme, create an override file
named `Monokai.sublime-color-scheme` in the Sublime Text User directory: >
{
"rules":
[
{
"scope": "neovintageous_search_inc",
"background": "#a1efe4",
"foreground": "#272822"
},
{
"scope": "neovintageous_search_cur",
"background": "#a1efe4",
"foreground": "#272822"
},
{
"scope": "neovintageous_search_occ",
"background": "#e6db74",
"foreground": "#272822"
}
]
}
==============================================================================
JUMPING TO DIFFS *nv-jumpto-diffs*
Two commands can be used to jump to diffs.
*[c*
[c Jump backwards to the previous start of a change.
When a count is used, do it that many times.
*]c*
]c Jump forwards to the next start of a change.
When a count is used, do it that many times.
It is an error if there is no change for the cursor to move to.
Note that in older versions of Sublime Text (builds < 3189) you will need the
the GitGutter package: https://github.com/jisaacks/GitGutter.
==============================================================================
TOGGLE COMMAND *nv-toggle*
If you want to be able to toggle NeoVintageous on and off, you need to install
the toggle package: https://packagecontrol.io/packages/ToggleNeoVintageous.
vim: tw=78 nu nowrap
You can’t perform that action at this time.