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 57343555fd77ad227900df4a

Split line with dots

This line is too long, split it.

Start file
class VimGolf
  def split_me
    MyModel.first_method.second_method(arg).third_method(arg.method_one.method_two)
  end
end
End file
class VimGolf
  def split_me
    MyModel
      .first_method
      .second_method(arg)
      .third_method(arg.method_one.method_two)
  end
end

View Diff

3c3,6
<     MyModel.first_method.second_method(arg).third_method(arg.method_one.method_two)
---
>     MyModel
>       .first_method
>       .second_method(arg)
>       .third_method(arg.method_one.method_two)

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 511 remaining solutions by signing in and submitting your own entry
#512 Jinotega / @Jinotega3000 - Score: 89 - 12/29/16 @ 20:54
jjWwi<CR><BS><BS><BS><BS><BS>      jk<BS><BS><Esc>wwwwijk<BS><BS>hi<BS><BS><Esc>i<CR><BS><BS><BS><BS><BS><BS><CR><BS><BS><BS><BS><BS>      <Esc>wwwwwwwwwbbbhi<CR><BS><BS><BS><BS><BS>      <Esc>j:wq<CR>

0 comments


Created by: @Benoit_Tgt

512 active golfers, 1747 entries

Leaderboard (lowest score wins):
21
#361 - Alejandro Claro / @alejandroclaro

07/09/2016 at 06:48PM

21
#362 - Charles Qian / @aWarmWalrus

07/12/2016 at 10:14PM

21
#363 - Anton Pidkuiko / @pidkuiko

07/14/2016 at 08:37AM

21
#364 - Christopher Fujino / @chrisfujino

07/17/2016 at 01:18AM

21
#365 - Alan Richards / @alarobric

07/17/2016 at 05:11AM

21
#366 - André Peric Tavares / @andre_peric

07/19/2016 at 06:15PM

21
#367 - Steven Moazami / @mong8se

07/19/2016 at 08:53PM

21
#368 - Roland Hougs / @OminousWater

07/24/2016 at 08:52PM

21
#369 - Matt Clement / @zetaspartan2552

07/31/2016 at 12:07AM

21
#370 - Stoyko Stanchev / @stoykostanchev

08/07/2016 at 08:26PM

21
#371 - Josh Samuelson / @JoshSamuelson

08/10/2016 at 02:04AM

21
#372 - kodemaan / @kodemaan

08/12/2016 at 07:18PM

21
#373 - Antoni Villalonga / @friki

08/15/2016 at 10:51AM

21
#374 - Nik Sun / @CandySunPlus

08/16/2016 at 06:37AM

21
#375 - Mort Rainey / @arch_midnight

08/18/2016 at 12:00AM

21
#376 - Alexander / @vlasyuk_a

09/06/2016 at 11:03AM

21
#377 - Constantine / @ConstantineHatz

09/12/2016 at 09:31PM

21
#378 - Andrew Jackson / @andrewj_nz

09/17/2016 at 08:01PM

21
#379 - Meriadec Pillet / @loomisBroom

09/27/2016 at 11:44AM

21
#380 - king_zorba / @StrangeZorba

09/28/2016 at 03:42PM

21
#381 - Netrisk Cool / @C00lt0

09/29/2016 at 06:16PM

21
#382 - Michael Hoffmann / @micha66545852

02/28/2017 at 03:28PM

21
#383 - MacBookGyver / @MacBookGyver

03/05/2017 at 10:30AM

21
#384 - Stephan Bugnon / @stephanbugnon

03/24/2017 at 05:01PM

21
#385 - Terrance Robotham / @t_robotham

04/11/2017 at 10:26AM

21
#386 - Joel Meyer-Hamme / @JoelMeyerHamme

06/20/2017 at 09:51PM

21
#387 - Owen / @owengeorge_

09/26/2017 at 12:28PM

21
#388 - Geoff / @RealGeoffErwin

09/29/2017 at 03:18PM

21
#389 - BPD / @brian_doyle

11/14/2017 at 01:27PM

21
#390 - BareTull / @BareTull3

12/03/2017 at 08:53PM