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 524e1a20b81fe50002000008

attr_aligner

Two attr keywords. Two separate indentations. Align the colons.

Start file
attr_reader :align, :variables, :with
attr_accessor :spaces, :to, :complete, :challenge
# vim: set expandtab:
End file
attr_reader :align,
            :variables,
            :with
attr_accessor :spaces,
              :to,
              :complete,
              :challenge
# vim: set expandtab:

View Diff

1,2c1,7
< attr_reader :align, :variables, :with
< attr_accessor :spaces, :to, :complete, :challenge
---
> attr_reader :align,
>             :variables,
>             :with
> attr_accessor :spaces,
>               :to,
>               :complete,
>               :challenge

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 620 remaining solutions by signing in and submitting your own entry
#621 ren / @wxoc - Score: 134 - 02/10/14 @ 07:05
f,a<CR><C-C><C-C>f,a<CR>j<C-H><C-C><C-C>jf,<CR>kf,a<CR><C-C><C-C>f,a<CR><C-C><C-C>f,<CR>klf,a<CR><C-C><C-C>ggvjjj=vgG<C-V><Esc>jlllllllli<Tab><C-C><C-C>ui    <C-C><C-C>jhhhi    <C-C><C-C>jjhhhi      <C-C><C-C>jhhhhhi      <C-C><C-C>jhhhhhi      <C-C><C-C>:wq<CR>

0 comments


Created by: @udioica

621 active golfers, 2968 entries

Leaderboard (lowest score wins):
22
#181 - Dimitar Dimitrov / @kurkale6ka

10/17/2013 at 02:23PM

22
#182 - John Phelan / @jackphel

02/02/2014 at 06:05PM

22
#183 - Steffen Siering / @ursobln

06/03/2014 at 12:03AM

22
#184 - bXpjE4GzUfnPTRHes1mI / @5DQzMDKJs2VoVt

06/26/2014 at 02:22PM

22
#185 - PLS / @jaegd

08/07/2014 at 01:22AM

22
#186 - Ram Tamtam / @ramtamtamtam

06/22/2016 at 02:30PM

22
#187 - Martin Tõnusoo / @martintonusoo

08/28/2016 at 10:31PM

22
#188 - Chris Robertson / @chrisxrobertson

05/05/2017 at 12:07PM

22
#189 - Guirec CORBEL / @GuirecCorbel

03/08/2018 at 01:17PM

23
#190 - Mac Heller-Ogden / @twosoul

11/23/2013 at 05:03PM

23
#191 - TerribleTrioJoe / @terribletriojoe

01/29/2014 at 10:49PM

23
#192 - Pierre Laporte / @pingtimeout

03/15/2014 at 10:33PM

23
#193 - Nam Net / @tafopigibi

11/29/2015 at 08:18AM

23
#194 - Ben Hill / @KaizenSoze70

05/22/2016 at 02:55PM

23
#195 - Luke Bryant / @LukeBryant55

10/07/2017 at 03:05PM

24
#196 - bunnies president / @bunnies4p

10/22/2013 at 03:16PM

24
#197 - Bradley M. Small / @BradleySmall

10/27/2013 at 01:40AM

24
#198 - Test User / @TestUserIgnore

12/04/2014 at 10:35PM

24
#199 - John Clara / @johnanthclara

08/21/2015 at 05:13AM

25
#200 - david ta / @tadavid

11/21/2013 at 08:11PM

25
#201 - Fabien Cazenave / @fabi1cazenave

01/02/2014 at 08:56PM

25
#202 - Mark Janssen / @MPCtje

01/15/2014 at 11:19AM

25
#203 - Luan Santos / @cfcluan

04/21/2014 at 08:32PM

25
#204 - Sntano Euhsk / @SEuhsk

06/04/2014 at 06:39AM

25
#205 - Yuriy / @skriyka

11/20/2014 at 09:56PM

25
#206 - Andrew Leung / @aleungpivotal

12/22/2014 at 07:09PM

25
#207 - Blake Tereau / @BlakeTereau

08/13/2015 at 06:32PM

25
#208 - Pratap Koritala / @pratap_koritala

02/21/2016 at 05:41AM

25
#209 - Mathias Andersson / @Wraul

02/22/2016 at 08:20PM

25
#210 - tgmeng / @lazy_fabric

06/10/2016 at 05:02AM