Deprecated: Function set_magic_quotes_runtime() is deprecated in /home/phaero/phaero.segolsson.se/wp-settings.php on line 18

Strict Standards: Declaration of Walker_Comment::start_lvl() should be compatible with Walker::start_lvl(&$output) in /home/phaero/phaero.segolsson.se/wp-includes/comment-template.php on line 0

Strict Standards: Declaration of Walker_Comment::end_lvl() should be compatible with Walker::end_lvl(&$output) in /home/phaero/phaero.segolsson.se/wp-includes/comment-template.php on line 0

Strict Standards: Declaration of Walker_Comment::start_el() should be compatible with Walker::start_el(&$output) in /home/phaero/phaero.segolsson.se/wp-includes/comment-template.php on line 0

Strict Standards: Declaration of Walker_Comment::end_el() should be compatible with Walker::end_el(&$output) in /home/phaero/phaero.segolsson.se/wp-includes/comment-template.php on line 0
Random Thoughts » Vim tips

Vim tips

If you want to search for something you select in visual mode: 1) yank 2) / 3) CTRL-R” 4) That is: y/^R” (note: ” is the default yank buffer. You could use a named buffer as well if you want.)

~ — switch case of character under cursor

i_CTRL-A — In insert mode, insert the previously inserted text.

{visual}g? — Rot13 encode highlighted text g?? — Rot13 encode the current line

CTRL-A — Add [count] to the number at or after the cursor CTRL-X — Subtract [count] from the number at or after the cursor

J - join the current line with the line below it.

. — repeat the last change

If you want to change a quotation: “This is a quotation” And want to change it to: “blablabla” Start on the first letter of the quotation and press ct” (Change Till “)

ga - with your cursor over a character, it will show you the decimal, hex, and octal codes of the character. Great for non printable characters.

To insert special characters, you’ll be interested in digraphs. :digraphs will show you a complete table of special characters, plus their two character code, plus their ascii number. You can insert digraphs using ctrl-k plus the two character code. For example ctrl-k SX results in ^B being inserted

Leave a Comment

You must be logged in to post a comment.