How do I copy files to a target directory using netrw's marking system?
mt and mc in netrw
Netrw, Vim's built-in file browser, has a full file-management workflow driven by marks.
2125 results for "i" a""
mt and mc in netrw
Netrw, Vim's built-in file browser, has a full file-management workflow driven by marks.
gM
The gM command moves the cursor to the horizontal middle of the current line, regardless of how long the line is.
ZZ
ZZ is a normal mode shorthand that saves and quits only if the buffer has been modified.
:keepmarks {command}
Many batch edits in Vim update special marks like '[ and '], which can disrupt follow-up motions or tooling that depends on those positions.
navigation #navigation #marks #command-line #refactoring #editing
gx
The gx command opens the URL, file path, or identifier under the cursor using the system's default handler.
navigation #navigation #netrw #workflow #browser #normal-mode
<C-y> / <C-e>
When typing in insert mode, you can pull individual characters from adjacent lines without leaving insert mode.
:undo {N}
:undo {N} lets you jump directly to the undo tree state after change number N was applied.
:keepmarks
When Vim executes commands that move or reorder lines — such as :sort, :%!sort, or :s/// across ranges — it automatically adjusts named marks to follow the
:set tags+=./tags;,tags
By default, Vim only looks for a tags file in the current directory.
:g/pattern/yank A
The :g command combined with yank A (uppercase A to append) lets you collect every line matching a pattern into a single register without overwriting previous c
command-line #editing #ex-commands #global-command #registers #filtering
<C-r><C-r>{register}
In insert mode, {reg} pastes from a register but treats certain bytes as key inputs — so a register containing \n triggers a newline, \x08 triggers backspace,
:%s/\v(\w+)/\u\1/g
Vim's substitute command supports case-modifier escapes in the replacement string: \u uppercases the next character, \U uppercases all text until \E or end of r
:keeppatterns {command}
The :keeppatterns modifier runs an Ex command — typically :s, :g, or :v — without modifying @/ (the last search pattern) or the command history.
command-line #ex-commands #search #substitution #command-line #scripting
:Cfilter /pattern/
Vim ships with an optional built-in package called cfilter that adds :Cfilter and :Lfilter commands for narrowing down quickfix and location list entries by pat
:'<,'>!column -t
When working with data that has uneven spacing — such as variable assignments, CSV-like data, or configuration entries — you can select the lines and pipe t
visual-mode #visual-mode #editing #formatting #external-command #alignment
:silent!
The :silent! modifier runs an Ex command without displaying any output or error messages.
:set inccommand=nosplit
When you are crafting a risky :substitute command, the expensive part is usually confidence, not typing.
<C-f> to scroll forward, <C-b> to scroll backward
How it works Vim provides two commands for scrolling by an entire screen (page) at a time: Ctrl-F (Forward) scrolls the view one full page down through the file
:g/pattern/cmd1 | cmd2
The :g (global) command can execute multiple Ex commands per matching line by chaining them with .
command-line #command-line #global #ex-commands #batch-editing #advanced
:ldo execute 'normal @q'
:ldo runs an Ex command on each entry in the location list — the buffer-local cousin of the quickfix list.