Skip to content

tool - vi moving arround

Apanding to the simple editing post i would like to add this time some hints for moving arround

  • ctrl+F - scroll forward one screen
  • ctrl+B - scroll backward one screen
  • ctrl+D - scroll forward half a screen
  • ctrl+U - scroll backward half a screen
  • H - move to the home/top line of the screen
  • M - move to the middle of the screen
  • L - move to the last line of the screen
  • + - move to the first character of the next line
  • - - move to the first character of the previous line
  • ? - search backward
  • N - step search backward

tool - vi a little more basics for simple editing

I am using the vi since a few years. A few months ago i realized that i am just using a bit of the mighty power of the vi. Thats why O`Reilly's Learning the vi editor was welcomed in my house :-). I have just finised a small part of the book but found already some "new" stuff for me. Thats why this entry is a supplement to my vi knowledge. But maybe there is something for you out there too.

  • :e! - returns you the last saved version of your file
  • W - move forward from word by word without considering symbols and punctuation
  • c2b - change two words backwards
  • c$ - change to the end of the line
  • cc - change the entire current line
  • C - change characters from current cursor position to the end of the line
  • s - substitute from current position
  • S - same as cc
  • R - puts you in "overwrite" mode
  • ~ - change case of your letter (Upper- to Lowercase and other way)
  • D - deletes from courrent position to the end of the line
  • x - deletes current character
  • X - deletes character before current position
  • xp - delete current character ad put after curser
  • y$ - yankes to the end of the line
  • . - repeats last command
  • O - opens blank line above curser
  • J - joins two (or more) lines
  • e - moves to the end of a word

Wow, after this list it is hard to believe that i am using the vi for years now, "we are absolute beginners" comes to my ears ;-).