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 5b71fa9105b5ca000ce4a7a1

convert yml into java pojo field

How fast vim can create fields for java pojo i.e class declaration referring to a (simple) yml file

Start file
- browser: Chrome
  browserVersion: 63
  os: window7
  osVersion: 2012
  lang: en
End file
private String browser;
private String browserVersion;
private String os;
private String osVersion;
private String lang;

View Diff

1,5c1,5
< - browser: Chrome
<   browserVersion: 63
<   os: window7
<   osVersion: 2012
<   lang: en
---
> private String browser;
> private String browserVersion;
> private String os;
> private String osVersion;
> private String lang;

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 153 remaining solutions by signing in and submitting your own entry
#154 Jurica / @Jurica34581259 - Score: 59 - 11/14/18 @ 23:35
:%s/:.*//g<CR>0qaxxkq4@a:%s/^/private String /g<CR>:%s/$/;/g<CR>:wq<CR>

0 comments


Created by: @saurabh908583

154 active golfers, 584 entries

Leaderboard (lowest score wins):
29
#31 - Ryan / @senorengineer

09/20/2018 at 10:09PM

29
#32 - Roger Bongers / @RogerBongers

10/02/2018 at 01:51PM

29
#33 - Dax / @zacoxi

10/05/2018 at 01:37AM

29
#34 - a / @UseForVim

10/05/2018 at 11:43AM

29
#35 - Will / @VVi11_I_AM

10/07/2018 at 08:46PM

29
#36 - Benjamin Kiesl / @BenjaminKiesl

10/11/2018 at 10:02AM

29
#37 - Sebastian Korten / @FlashKorten

10/13/2018 at 11:14AM

29
#38 - ajsantander / @_ajsantander

10/18/2018 at 01:21AM

29
#39 - Chris Budetti / @ChrisBudetti

10/19/2018 at 10:47AM

29
#40 - Finn Francis / @FinnFrancis

10/27/2018 at 12:01AM

29
#41 - Dima Matrohin / @wo_ogy

10/27/2018 at 09:49AM

29
#42 - Ole Mussmann / @isbjornlabs

10/28/2018 at 11:28AM

29
#43 - Iciciliser / @Iciciliser

10/28/2018 at 02:09PM

29
#44 - Henrique Malheiro / @rike09

11/11/2018 at 11:17PM

29
#45 - name / @name65894813

11/14/2018 at 07:51PM

29
#46 - Wouter Horlings / @Achilleshiel

11/15/2018 at 11:38AM

29
#47 - Jonathan Cabezas / @John_Harkan

11/27/2018 at 10:42AM

29
#48 - Mihai / @mihaicristiant

11/27/2018 at 08:47PM

29
#49 - CptBong / @cpt1bong

11/28/2018 at 12:33AM

29
#50 - Maas Lalani / @maaslalani

12/03/2018 at 06:08PM

29
#51 - Artur Mróz / @MrozArtur

12/06/2018 at 11:12AM

29
#52 - Théo / @Theodnls

12/17/2018 at 03:17PM

29
#53 - TimMcGuire / @mcguire

12/25/2018 at 07:21PM

29
#54 - pankaj singh / @pankajsingh013

01/15/2019 at 10:34AM

29
#55 - amal / @cdsudama

02/03/2019 at 05:23AM

29
#56 - Sebastien Nicoud / @sebnukem

02/03/2019 at 10:10PM

29
#57 - tenteke / @kuskus3

02/12/2019 at 02:18PM

29
#58 - Groovy / @groovy9

03/07/2019 at 10:16PM

29
#59 - james_bunch / @james_bunch

03/23/2019 at 07:21PM

30
#60 - h43z / @h43z

08/14/2018 at 01:37AM