I post daily tips related to using the vim text editor
Public Key
npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f
Profile Code
nprofile1qqsdedsfg0ts3h6u0wh0p0xqrg7jnnrag6sn6ckw27294wq5cnjulpspzemhxue69uhhyetvv9ujumn0wd68ytnzv9hxgqg4waehxw309aex2mrp0yhx6mmnw3ezuur4vgwue4cz
Author Public Key
npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Show more details
Published at
2023-05-02T06:33:17Z Event JSON
{
"id": "c3eebeb7730ba151dee4485250dab769cb8f6c034ffea86a6ad3292bcdf4f2f8" ,
"pubkey": "dcb60943d708df5c7baef0bcc01a3d29cc7d46a13d62ce57945ab814c4e5cf86" ,
"created_at": 1683009197 ,
"kind": 0 ,
"tags": [
[
"mostr",
"https://botsin.space/users/vimtips"
]
],
"content": "{\"name\":\"Vim Tips\",\"about\":\"I post daily tips related to using the vim text editor\",\"picture\":\"https://files.botsin.space/accounts/avatars/000/262/945/original/d554909b2bfd7144.png\",\"banner\":\"https://files.botsin.space/accounts/headers/000/262/945/original/51ab56a2ed4f0003.png\",\"nip05\":\"[email protected] \"}" ,
"sig": "37d8de2ddd038d87b634a4c1144e548484f8ccade497481e7585cb1972e1d9ad15f62a6a4eda4723c1b3e3ad5538a7729bc43d407d8c025e37ad8e1dbde00f01"
}
Last Notes npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Here's a vim tip, A lot of these tips come from https://vim.fandom.com/wiki/Best_Vim_Tips. Check out the wiki site for many more tips! npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Vim tip of the day! Using vim to type up professional documents? You can get vim to spellcheck by typing ':set spell'. You can also permanently enable spellcheck by adding that to your .vimrc file. npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Vim is super useful! Try this? Press 'v' from NORMAL mode to enable VISUAL selection mode. Use arrow keys to then make your selection and enter a hotkey like y or d to yank (copy) or delete the selection, respectively. npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Use Shift+5 (the percent sign on en-US keyboard layouts) to skip to the matching bracket, brace, or parenthesis pair npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips This vim tip may be useful From COMMAND mode, to switch between opened tabs type tabprevious and tabnext respectively npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Vim is super useful! Try this? Use 'i' or 'a' to enter INSERT mode, placing the cursor before or after the NORMAL mode cursor, respectively. Use 'I' or 'A' to enter INSERT mode, moving the cursor to the start or end of the current line, respectively. npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Vim is super useful! Try this? Use 'i' or 'a' to enter INSERT mode, placing the cursor before or after the NORMAL mode cursor, respectively. Use 'I' or 'A' to enter INSERT mode, moving the cursor to the start or end of the current line, respectively. npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Vim can be configured out the wazoo, try this Use x to create a new line npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Did you know this? From NORMAL mode, to undo type u, to redo press Ctrl + r npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips :Ni! npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Tip of the day :help UserGettingBored npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Vim is super useful! Try this? From COMMAND mode, to open a new horizontal split type split <optional file> npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips In vim: :help bar npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips This vim tip may be useful From NORMAL mode, to correct a word (regardless of the cursor position) type ciw npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Quit vim by typing ESC, :q, ENTER. Also, try this: From NORMAL mode, type 'guu' or 'gUU' to make the entire current line lowercase or uppercase, respectively. npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Try this in vim To enable syntax highlighting in vim (based on the file's extension like .py or .html), type the command ':syntax on'. Add ':syntax on' to your .vimrc to set it permanently. npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips In vim: Use u in vim to undo the last operation npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Vim is super useful! Try this? Vim can do word completion! If there's a word that you use often in your document but can't remember how to spell it, start the word and press Ctrl+P to give suggestions based on previous usage of the word. npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips Vim is super useful! Try this? From NORMAL mode, to move to the beginning and end of the line type 0 and $ respectively npub1mjmqjs7hpr04c7aw7z7vqx3a98x8634p843vu4u5t2upf389e7rqwexs4f Vim Tips From NORMAL mode, to move to the beginning and end of the line type 0 and $ respectively