diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2016-02-05 15:00:00 -0800 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2016-02-05 15:00:00 -0800 |
commit | 686113531d23f30e9973d659c456ae33eb9cff1f (patch) | |
tree | f225de7251a8b49b8d183dd168bab0a0addbe23f /lib/chef/resource/cron.rb | |
parent | d1cf34b059a16a81e0fc48de52ba29863bb41fe6 (diff) | |
download | chef-686113531d23f30e9973d659c456ae33eb9cff1f.tar.gz |
autofixing whitespace cops
4174 Style/SpaceInsideHashLiteralBraces
1860 Style/SpaceAroundOperators
1336 Style/SpaceInsideBlockBraces
1292 Style/AlignHash
997 Style/SpaceAfterComma
860 Style/SpaceAroundEqualsInParameterDefault
310 Style/EmptyLines
294 Style/IndentationConsistency
267 Style/TrailingWhitespace
238 Style/ExtraSpacing
212 Style/SpaceBeforeBlockBraces
166 Style/MultilineOperationIndentation
144 Style/TrailingBlankLines
120 Style/EmptyLineBetweenDefs
101 Style/IndentationWidth
82 Style/SpaceAroundBlockParameters
40 Style/EmptyLinesAroundMethodBody
29 Style/EmptyLinesAroundAccessModifier
1 Style/RescueEnsureAlignment
Diffstat (limited to 'lib/chef/resource/cron.rb')
-rw-r--r-- | lib/chef/resource/cron.rb | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/lib/chef/resource/cron.rb b/lib/chef/resource/cron.rb index e105cc94d8..26711fde16 100644 --- a/lib/chef/resource/cron.rb +++ b/lib/chef/resource/cron.rb @@ -30,7 +30,7 @@ class Chef default_action :create allowed_actions :create, :delete - def initialize(name, run_context=nil) + def initialize(name, run_context = nil) super @minute = "*" @hour = "*" @@ -47,7 +47,7 @@ class Chef @environment = {} end - def minute(arg=nil) + def minute(arg = nil) if arg.is_a?(Integer) converted_arg = arg.to_s else @@ -64,7 +64,7 @@ class Chef ) end - def hour(arg=nil) + def hour(arg = nil) if arg.is_a?(Integer) converted_arg = arg.to_s else @@ -81,7 +81,7 @@ class Chef ) end - def day(arg=nil) + def day(arg = nil) if arg.is_a?(Integer) converted_arg = arg.to_s else @@ -98,7 +98,7 @@ class Chef ) end - def month(arg=nil) + def month(arg = nil) if arg.is_a?(Integer) converted_arg = arg.to_s else @@ -115,7 +115,7 @@ class Chef ) end - def weekday(arg=nil) + def weekday(arg = nil) if arg.is_a?(Integer) converted_arg = arg.to_s else @@ -123,11 +123,11 @@ class Chef end begin error_message = "You provided '#{arg}' as a weekday, acceptable values are " - error_message << Provider::Cron::WEEKDAY_SYMBOLS.map {|sym| ":#{sym}"}.join(", ") + error_message << Provider::Cron::WEEKDAY_SYMBOLS.map { |sym| ":#{sym}" }.join(", ") error_message << " and a string in crontab format" if (arg.is_a?(Symbol) && !Provider::Cron::WEEKDAY_SYMBOLS.include?(arg)) || - (!arg.is_a?(Symbol) && integerize(arg) > 7) || - (!arg.is_a?(Symbol) && integerize(arg) < 0) + (!arg.is_a?(Symbol) && integerize(arg) > 7) || + (!arg.is_a?(Symbol) && integerize(arg) < 0) raise RangeError, error_message end rescue ArgumentError @@ -139,7 +139,7 @@ class Chef ) end - def time(arg=nil) + def time(arg = nil) set_or_return( :time, arg, @@ -147,7 +147,7 @@ class Chef ) end - def mailto(arg=nil) + def mailto(arg = nil) set_or_return( :mailto, arg, @@ -155,7 +155,7 @@ class Chef ) end - def path(arg=nil) + def path(arg = nil) set_or_return( :path, arg, @@ -163,7 +163,7 @@ class Chef ) end - def home(arg=nil) + def home(arg = nil) set_or_return( :home, arg, @@ -171,7 +171,7 @@ class Chef ) end - def shell(arg=nil) + def shell(arg = nil) set_or_return( :shell, arg, @@ -179,7 +179,7 @@ class Chef ) end - def command(arg=nil) + def command(arg = nil) set_or_return( :command, arg, @@ -187,7 +187,7 @@ class Chef ) end - def user(arg=nil) + def user(arg = nil) set_or_return( :user, arg, @@ -195,7 +195,7 @@ class Chef ) end - def environment(arg=nil) + def environment(arg = nil) set_or_return( :environment, arg, |