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 4fcd8dc2ff37f20001000020

Create a pandoc compatible table

In [this vimcast][1], a featured gist from Tim Pope shows how to quickly make a simple table structure. How fast can you convert it to pandoc's markdown style? [1]: http://vimcasts.org/episodes/aligning-text-with-tabular-vim/

Start file
| This  | Is    | A Table   | Example     |
| I'm   | going | to        | fill        |
| it    | with  | random    | information |
| just  | to    | save      | me          |
| time. | In    | the       | spirit      |
| of    | vim   | I         | am          |
| quite | often | extremely | lazy.       |
End file
This   Is     A Table    Example
-----  -----  ---------  -----------
I'm    going  to         fill
it     with   random     information
just   to     save       me
time.  In     the        spirit
of     vim    I          am
quite  often  extremely  lazy.

View Diff

1,7c1,8
< | This  | Is    | A Table   | Example     |
< | I'm   | going | to        | fill        |
< | it    | with  | random    | information |
< | just  | to    | save      | me          |
< | time. | In    | the       | spirit      |
< | of    | vim   | I         | am          |
< | quite | often | extremely | lazy.       |
---
> This   Is     A Table    Example
> -----  -----  ---------  -----------
> I'm    going  to         fill
> it     with   random     information
> just   to     save       me
> time.  In     the        spirit
> of     vim    I          am
> quite  often  extremely  lazy.

Solutions

The best way to learn is to practice. Below, you will find some of the solutions other golfers have entered. To unlock higher ranked solutions, submit your own entry which does as well or better than the solutions you can currently see - climb the ladder!

Check out these helpful resources to improve your Vim skills... Game on.

Unlock 50 remaining solutions by signing in and submitting your own entry
#51 Angela Harms / @angelaharms - Score: 84 - 06/19/12 @ 23:08
:%s/|//g<BS>g<CR>:%/<BS>s/^ //h<BS><CR>:%s/\s\+$/<CR>:1a<CR>:<BS>-----  -----  ---------  -----------<CR>.<CR>:wq<CR>

0 comments


Created by: @connermcd

51 active golfers, 177 entries

Leaderboard (lowest score wins):
47
#31 - じょんあば / @john_ababa

06/08/2012 at 03:14PM

47
#32 - Steven Occhipinti / @steveocchipinti

06/12/2012 at 03:10AM

47
#33 - J Paul Daigle / @philosodad

06/16/2012 at 11:53AM

49
#34 - Dil / @dilpun

06/08/2012 at 02:19PM

49
#35 - Underhill Labs / @underhilllabs

10/30/2012 at 05:05AM

50
#36 - shutl_test / @shutl_test

06/06/2012 at 09:00PM

50
#37 - vimgolf dp / @DpVimgolf

06/12/2012 at 10:09PM

50
#38 - Yann Moisan / @YannMoisan

01/26/2013 at 08:17AM

52
#39 - Ilya Ermolin / @ermolinis

06/21/2012 at 07:26AM

55
#40 - james_bunch / @james_bunch

05/26/2019 at 03:11AM

56
#41 - squdle / @squdle

06/17/2017 at 12:28PM

57
#42 - John Whitley / @johnwhitley

06/05/2012 at 04:02PM

64
#43 - Oliver Mader / @dotb52

07/17/2012 at 07:33AM

65
#44 - mnx / @mnxx

06/05/2012 at 10:05PM

66
#45 - Guillaume Seren / @guillaumeseren

11/21/2014 at 05:08PM

69
#46 - ise0615 / @ise0615

06/15/2012 at 05:28AM

74
#47 - Mikael Engström / @mikaelengstrom

06/05/2012 at 02:07PM

76
#48 - Jason Felice / @eraserhd

06/19/2012 at 11:05PM

81
#49 - Jan Wedekind / @wedesoft

07/13/2012 at 06:59PM

81
#50 - Tom Cammann / @tea_sea

10/09/2012 at 11:56PM

84
#51 - Angela Harms / @angelaharms

06/19/2012 at 11:08PM