How do I use a counter variable inside a Vim macro?
: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.
105 results for "buffer number"
: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.
gf
The gf command ("go to file") opens the file whose path is under the cursor.
navigation #navigation #normal-mode #buffers #productivity #file-management
:set formatexpr=MyFormat()
The formatexpr option lets you replace Vim's built-in line-breaking logic for the gq operator with your own Vimscript expression or function.
:lua require('ufo').openAllFolds()
nvim-ufo is a Neovim plugin that replaces the built-in fold system with one powered by LSP (textDocument/foldingRange) or treesitter.
vim-sleuth
The vim-sleuth plugin by Tim Pope automatically detects the indentation style (tabs vs spaces) and width used in a file and sets shiftwidth, expandtab, tabstop,