Go to first line in a file in vim?

Jean picture Jean · Apr 1, 2011 · Viewed 181.6k times · Source

How do I go to first line in a file in vim ?

Answer

Lazer picture Lazer · Apr 1, 2011

In command mode (press Esc if you are not sure) you can use:

  • gg,
  • :1,
  • 1G,
  • or 1gg.