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

Reformat long lines

Rearrange this ruby method call to put each parameter on its own line. Could become a useful macro.

Start file
def default_i18n_subject
  mailer_scope = self.class.mailer_name.gsub('/', '.')
  I18n.t(:subject, :scope => [mailer_scope, action_name], :default => action_name.humanize)
end
End file
def default_i18n_subject
  mailer_scope = self.class.mailer_name.gsub('/', '.')
  I18n.t(:subject,
         :scope => [mailer_scope, action_name],
         :default => action_name.humanize)
end

View Diff

3c3,5
<   I18n.t(:subject, :scope => [mailer_scope, action_name], :default => action_name.humanize)
---
>   I18n.t(:subject,
>          :scope => [mailer_scope, action_name],
>          :default => action_name.humanize)

Solutions by @nelstrom:

Unlock 7 remaining solutions by signing in and submitting your own entry
Created by: @sermoa

134 active golfers, 358 entries

Solutions by @nelstrom:
15
#18 - Drew Neil / @nelstrom

11/27/2012 at 12:32AM

16
#>36 - Drew Neil / @nelstrom

11/27/2012 at 12:32AM

17
#>65 - Drew Neil / @nelstrom

11/27/2012 at 12:30AM

18
#>75 - Drew Neil / @nelstrom

11/27/2012 at 12:29AM

21
#>104 - Drew Neil / @nelstrom

11/27/2012 at 12:28AM

24
#>129 - Drew Neil / @nelstrom

11/27/2012 at 12:27AM

25
#>130 - Drew Neil / @nelstrom

11/27/2012 at 12:26AM