Another vim pro-tip today. This one is pretty basic, but if you don’t know it, it can save you a whole bunch of typing.

A lot of times, whether it be while testing, greping, or acking you know the line you want to go to before you open a file.

When launching vim, you can specify the number to open the first file to, like:

$ vim somefile.rb +24

And the cursor will be placed at the beginning of that line, centered on the screen.