How to fill a line with character x up to column y using Vim
You can do 80Ax<Esc>d80| for a simpler solution.
You can do 80Ax<Esc>d80| for a simpler solution.
There’s also surround.vim, if you’re looking to do this fairly often. You’d use cs'” to change surrounding quotes.
Based on your feedback to my first answer, how about this: (defun my-isearch-word-at-point () (interactive) (call-interactively ‘isearch-forward-regexp)) (defun my-isearch-yank-word-hook () (when (equal this-command ‘my-isearch-word-at-point) (let ((string (concat “\\<” (buffer-substring-no-properties (progn (skip-syntax-backward “w_”) (point)) (progn (skip-syntax-forward “w_”) (point))) “\\>”))) (if (and isearch-case-fold-search (eq ‘not-yanks search-upper-case)) (setq string (downcase string))) (setq isearch-string string isearch-message (concat isearch-message (mapconcat … Read more
Use the :tn and :tp sequences to navigate between tags. If you want to look for the next tag on the same help page, try this search: /|.\{-}| This means to search for: The character | Any characters up to the next |, matching as few as possible (that’s what \{-} does). Another character | … Read more
You can use the setting :se nostartofline or short: :se nosol Documentation: *’startofline’* *’sol’* *’nostartofline’* *’nosol’* ‘startofline’ ‘sol’ boolean (default on)` global {not in Vi} When “on” the commands listed below move the cursor to the first non-blank of the line. When off the cursor is kept in the same column (if possible). This applies … Read more
I found the Vim documentation for vimscript, which has a section on variables: To delete a variable use the “:unlet” command. Example: :unlet s:count
Just repeat the object selection keys. For your examples this would be va}a} or vi]i]. I don’t think that there is a way to then reduce the selection back to an inner block. Other than to use Esc to clear the selection, “ to jump back to your starting poing and then redo the initial … Read more
In ubuntu, the default vim install comes from the package vim-tiny, which isn’t the whole thing. You probably want to: apt-get install vim or apt-get install vim-full Some of your other problems sound like issues with the backspace key and other things. Once you get the full version of vim, try adding these to your … Read more
The + motion moves to the first non-blank character in the next ([count]) line. That fulfills your requirement if there’s no indent. With indent, you can use +0 or j0.
You asked what I’m looking for today. I found a simpler solution than those presented here. I want transparent background instead of the black background from the theme, while simply overriding the color after the colorscheme statement in .vimrc doesn’t work and installing a plugin just for that is weird. Here is what I did: … Read more