summaryrefslogtreecommitdiff
path: root/chef-config
diff options
context:
space:
mode:
authorJay Mundrawala <jdmundrawala@gmail.com>2016-02-16 21:16:45 -0800
committerJay Mundrawala <jdmundrawala@gmail.com>2016-02-24 21:24:15 -0800
commitb5b94dc98bca9e0158b6ddab29e14ca4edf5ac02 (patch)
treeb63f367a9095c110e1ac0099963e1a421f2cc984 /chef-config
parent05f5c6727a9dc9f32ef78bafb059f2dd26194724 (diff)
downloadchef-b5b94dc98bca9e0158b6ddab29e14ca4edf5ac02.tar.gz
Use escape_glob_dir for client.d/conf.d
Passing the value of `escape_glob` to Dir.glob does not always work correctly on Windows. Always use forward slashes when globbing, even on Windows. We now do this via `escape_glob_dir`, which calls Pathname.cleanpath, which does the foward slash thing.
Diffstat (limited to 'chef-config')
-rw-r--r--chef-config/lib/chef-config/workstation_config_loader.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/chef-config/lib/chef-config/workstation_config_loader.rb b/chef-config/lib/chef-config/workstation_config_loader.rb
index 63731b729d..efc7049ec1 100644
--- a/chef-config/lib/chef-config/workstation_config_loader.rb
+++ b/chef-config/lib/chef-config/workstation_config_loader.rb
@@ -136,7 +136,7 @@ module ChefConfig
@conf_d_files ||=
begin
entries = Array.new
- entries << Dir.glob(File.join(PathHelper.escape_glob(
+ entries << Dir.glob(File.join(PathHelper.escape_glob_dir(
Config[:conf_d_dir]), "*.rb")) if Config[:conf_d_dir]
entries.flatten.select do |entry|
File.file?(entry)