summaryrefslogtreecommitdiff
path: root/lib/chef/chef_fs/config.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/chef_fs/config.rb')
-rw-r--r--lib/chef/chef_fs/config.rb10
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/chef/chef_fs/config.rb b/lib/chef/chef_fs/config.rb
index 19cea3b4ea..913a4097a3 100644
--- a/lib/chef/chef_fs/config.rb
+++ b/lib/chef/chef_fs/config.rb
@@ -26,7 +26,6 @@ class Chef
# objects representing the server and local repository, respectively).
#
class Config
-
# Not all of our object types pluralize by adding an 's', so we map them
# out here:
INFLECTIONS = {
@@ -44,7 +43,7 @@ class Chef
"policies" => "policy",
"policy_groups" => "policy_group",
}
- INFLECTIONS.each { |k,v| k.freeze; v.freeze }
+ INFLECTIONS.each { |k, v| k.freeze; v.freeze }
INFLECTIONS.freeze
# ChefFS supports three modes of operation: "static", "everything", and
@@ -74,7 +73,6 @@ class Chef
EVERYTHING_MODE_OBJECT_NAMES = (CHEF_11_OSS_STATIC_OBJECTS + CHEF_11_OSS_DYNAMIC_OBJECTS).freeze
HOSTED_EVERYTHING_MODE_OBJECT_NAMES = (EVERYTHING_MODE_OBJECT_NAMES + RBAC_OBJECT_NAMES + CHEF_12_OBJECTS).freeze
-
#
# Create a new Config object which can produce a chef_fs and local_fs.
#
@@ -243,12 +241,12 @@ class Chef
# Print the given server path, relative to the current directory
def format_path(entry)
server_path = entry.path
- if base_path && server_path[0,base_path.length] == base_path
+ if base_path && server_path[0, base_path.length] == base_path
if server_path == base_path
return "."
- elsif server_path[base_path.length,1] == "/"
+ elsif server_path[base_path.length, 1] == "/"
return server_path[base_path.length + 1, server_path.length - base_path.length - 1]
- elsif base_path == "/" && server_path[0,1] == "/"
+ elsif base_path == "/" && server_path[0, 1] == "/"
return server_path[1, server_path.length - 1]
end
end