How do I toggle line wrapping on or off in Vim?
:set wrap! or :set nowrap
How it works By default, Vim wraps long lines that extend past the window width, displaying them across multiple screen lines.
414 results for "G"
:set wrap! or :set nowrap
How it works By default, Vim wraps long lines that extend past the window width, displaying them across multiple screen lines.
grn / grc / grm
Neovim's nvim-treesitter plugin provides incremental selection based on the abstract syntax tree (AST) of your code.
{count}@{register}
Prefix any macro execution with a count to repeat it that many times in a single command.
@:
The @: command re-executes the most recently run Ex command (any command starting with :).
command-line #command-line #ex-commands #repeat #normal-mode #productivity
"+p
The "+p command pastes the contents of the system clipboard into Vim.
"Ayy
The "Ayy command appends the current line to register a instead of overwriting it.
<C-f> (from command-line mode)
When you are partway through typing a long or complex Ex command on the : prompt, you can press to open the command-line window.
:r filename
The :r filename command reads the contents of filename and inserts them into the current buffer below the cursor line.
ysiw)
The vim-surround plugin provides the ys (you surround) operator to wrap any Vim text object or motion with a delimiter pair.
plugins #plugins #surround #editing #text-objects #normal-mode
"+y
The "+y command yanks (copies) text into the system clipboard register, making it available to paste in other applications outside of Vim.
"%p
The % register in Vim always contains the name of the current file.
registers #registers #editing #insert-mode #productivity #filename
:let i=1 then use <C-r>=i<CR> in macro
By combining a Vimscript variable with the expression register inside a macro, you can create a counter that increments on each replay.
:r !command
The :r !command command executes a shell command and inserts its output directly into the current buffer below the cursor line.
qaqqa{actions}@aq@a
A recursive macro is a macro that calls itself at the end of its recording.
oil.nvim: edit directory listing like a buffer
oil.
gf
The gf command ("go to file") opens the file whose path is under the cursor.
navigation #navigation #normal-mode #buffers #productivity #file-management
<C-v>
The (Ctrl+v) command enters visual block mode, which lets you select a rectangular column of text across multiple lines.
:terminal
The :terminal command opens an interactive terminal emulator directly inside a Vim window.
:Git blame
The vim-fugitive plugin by Tim Pope provides a powerful interactive :Git blame that goes far beyond the basic command-line git blame.
:redir @a | {cmd} | redir END
The :redir command redirects the output of Ex commands to a register, file, or variable instead of displaying it on the screen.
command-line #command-line #ex-commands #registers #productivity #advanced