summaryrefslogtreecommitdiff
path: root/lib/chef/platform
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2016-02-18 18:39:11 -0800
committerLamont Granquist <lamont@scriptkiddie.org>2016-02-18 18:39:11 -0800
commit6077b99f6ad1bc9a082f575f3818e69f05d8c8dc (patch)
treeae132bad653614ae549e6301a01f991f8cf5cb5b /lib/chef/platform
parent8f9a0dbd88de3014161bebfef7a02821e0010a37 (diff)
downloadchef-6077b99f6ad1bc9a082f575f3818e69f05d8c8dc.tar.gz
deal with 0.37.2 renamed cops
252 Style/TrailingCommaInLiteral 84 Style/TrailingCommaInArguments 15 Style/SpaceAroundKeyword -- 351 Total We already dealt with SpaceAroundKeyword under its old name SpaceBeforeModifierKeyword, it looks like it got stricter about spaces after keywords. TrailingComma also got split, and it looks like the TrailingCommaInArguments behavior is new?
Diffstat (limited to 'lib/chef/platform')
-rw-r--r--lib/chef/platform/provider_mapping.rb16
-rw-r--r--lib/chef/platform/service_helpers.rb2
2 files changed, 9 insertions, 9 deletions
diff --git a/lib/chef/platform/provider_mapping.rb b/lib/chef/platform/provider_mapping.rb
index d24cd8c18c..1a5da902ef 100644
--- a/lib/chef/platform/provider_mapping.rb
+++ b/lib/chef/platform/provider_mapping.rb
@@ -119,10 +119,10 @@ class Chef
:required => false,
},
:resource => {
- :kind_of => Symbol
+ :kind_of => Symbol,
},
:provider => {
- :kind_of => [ String, Symbol, Class ]
+ :kind_of => [ String, Symbol, Class ],
},
},
)
@@ -133,14 +133,14 @@ class Chef
platforms[args[:platform]][args[:version]][args[:resource].to_sym] = args[:provider]
else
platforms[args[:platform]][args[:version]] = {
- args[:resource].to_sym => args[:provider]
+ args[:resource].to_sym => args[:provider],
}
end
else
platforms[args[:platform]] = {
args[:version] => {
- args[:resource].to_sym => args[:provider]
- }
+ args[:resource].to_sym => args[:provider],
+ },
}
end
else
@@ -155,8 +155,8 @@ class Chef
else
platforms[args[:platform]] = {
:default => {
- args[:resource].to_sym => args[:provider]
- }
+ args[:resource].to_sym => args[:provider],
+ },
}
end
end
@@ -165,7 +165,7 @@ class Chef
platforms[:default][args[:resource].to_sym] = args[:provider]
else
platforms[:default] = {
- args[:resource].to_sym => args[:provider]
+ args[:resource].to_sym => args[:provider],
}
end
end
diff --git a/lib/chef/platform/service_helpers.rb b/lib/chef/platform/service_helpers.rb
index 87b87d4c72..28c4c5ec59 100644
--- a/lib/chef/platform/service_helpers.rb
+++ b/lib/chef/platform/service_helpers.rb
@@ -105,7 +105,7 @@ class Chef
def has_systemd_service_unit?(svc_name)
%w{ /etc /usr/lib /lib /run }.any? do |load_path|
::File.exist?(
- Chef.path_to("#{load_path}/systemd/system/#{svc_name.gsub(/@.*$/, '@')}.service")
+ Chef.path_to("#{load_path}/systemd/system/#{svc_name.gsub(/@.*$/, '@')}.service"),
)
end
end