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 652 remaining solutions by signing in and submitting your own entry
#653 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

653 active golfers, 3202 entries

Leaderboard (lowest score wins):
19
#151 - alekfed / @alek_fed

04/15/2019 at 09:16AM

19
#152 - Grant / @grant_7788

04/30/2019 at 01:55PM

19
#153 - Sherab Giovannini / @shaddycls

05/18/2019 at 11:48PM

19
#154 - Miłosz Łakomy / @foobar01123

07/14/2019 at 09:26AM

19
#155 - sooqua / @sooqua

08/08/2019 at 10:14PM

19
#156 - Malcolm Sharpe / @blueblimpms

08/12/2019 at 06:50PM

19
#157 - Daisuke Ito / @itodais

08/21/2019 at 12:01PM

19
#158 - Martin Delille / @martinodelilo

08/27/2019 at 02:01PM

19
#159 - じんぺー / @jinpei0908

09/07/2019 at 06:55AM

19
#160 - dicekest / @dicekest

09/12/2019 at 12:53PM

19
#161 - Rui Xue / @ruirayxue

10/03/2019 at 02:47PM

19
#162 - Viktor Styrud / @ViktorStyrud

10/08/2019 at 06:25AM

19
#163 - Delon / @delonleonard

12/30/2019 at 01:06PM

19
#164 - Bachelor / @bachelorwang

02/04/2020 at 10:07AM

19
#165 - Jonathan Stinson / @KnightdeadJohn

02/18/2020 at 04:55PM

19
#166 - floyd / @floyd10086

03/20/2020 at 09:30AM

19
#167 - howanto / @ho_wan_

03/21/2020 at 02:02PM

20
#168 - StarkHalo / @hellektor

10/06/2013 at 05:18AM

20
#169 - Jan Bundesmann / @janbundesmann

03/17/2016 at 02:23PM

20
#170 - Mihai / @mihaicristiant

12/03/2018 at 06:23PM

20
#171 - 默罕默德 / @Rt6RjEAJ987Woes

02/18/2019 at 11:52AM

20
#172 - 田中太郎 / @hidecham55

05/17/2019 at 04:40AM

20
#173 - Chester Yap / @Chest_ErYap

07/11/2019 at 04:05AM

20
#174 - Jason Neylon / @jasonneylon

01/27/2020 at 07:43PM

21
#175 - retired account / @retired10072015

10/05/2013 at 06:09PM

21
#176 - aRkadeFR / @aRkadeFR

10/06/2013 at 07:13PM

21
#177 - Tzipan / @Tzipan

10/23/2013 at 07:55PM

21
#178 - Ruy Diaz / @diazruy

11/06/2013 at 01:41AM

21
#179 - JamesT / @jamestrinklein

01/29/2014 at 07:15AM

21
#180 - Strabs / @artistavenue

02/03/2014 at 03:13PM