Real Vim ninjas count every keystroke - do you?

Pick a challenge, fire up Vim, and show us what you got.

Changelog, Rules & FAQ, updates: @vimgolf, RSS.

Your VimGolf key: please sign in

$ gem install vimgolf
$ vimgolf setup
$ vimgolf put [challenge ID]

Played Challenges

Just the middle - 11141 entries

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 7
  • Position: #195 / 4114
  • Number of attempts: 3
Basic renumbering - 5436 entries

Renumbering Basic.

  • Best score: 11
  • Best player score: 14
  • Position: #344 / 1228
  • Number of attempts: 5
Interleave lines - 134 entries

This is some kind of « paste -d'\n' c b a ». There are many ways to achieve this.. just find the shortest!

  • Best score: 17
  • Best player score: 17
  • Position: #2 / 55
  • Number of attempts: 5
I forgot quotes - 15748 entries

Oops.

  • Best score: 10
  • Best player score: 10
  • Position: #131 / 4116
  • Number of attempts: 4
Words in parens - 12736 entries

We should all ace this, right?

  • Best score: 13
  • Best player score: 14
  • Position: #512 / 3919
  • Number of attempts: 3
Changing URL path in CSS - 123 entries

What's the quickest way to swap out all the URLs in a CSS file? Is it wasted keystrokes using look-behinds and look-aheads? (I'm sorry for the delete/report--I made a mistake with the last one requiring an ugly search for graphic to replace with images. I just intended this to be a simple search and replace that might possibly generate some macros or normals solutions that are quicker)

  • Best score: 40
  • Best player score: 40
  • Position: #13 / 57
  • Number of attempts: 3
Simple text editing with Vim - 11657 entries

Make the pairs of lines match up by making each second line same as first

  • Best score: 13
  • Best player score: 14
  • Position: #916 / 3418
  • Number of attempts: 5
Kaleb Hornsby
Twitter:

♂♐犬✝⚭中☫

entered into 7 challenges

contributed 0 challenges