diff options
author | John Keiser <jkeiser@opscode.com> | 2013-05-19 10:02:13 -0700 |
---|---|---|
committer | John Keiser <jkeiser@opscode.com> | 2013-06-07 13:12:33 -0700 |
commit | ead004dc367ca9cb62cbe259f4f456e286c5f35c (patch) | |
tree | bbbf9a6d6bc2df788ed5be7939106a9e8fe31afd /lib/chef/knife/download.rb | |
parent | 421fea23afaed6eddd76654757b25c88c49808a6 (diff) | |
download | chef-ead004dc367ca9cb62cbe259f4f456e286c5f35c.tar.gz |
Fix bug where we didn't go through all patterns if the first one failed
Diffstat (limited to 'lib/chef/knife/download.rb')
-rw-r--r-- | lib/chef/knife/download.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/chef/knife/download.rb b/lib/chef/knife/download.rb index 26abcb3acd..a8178a9434 100644 --- a/lib/chef/knife/download.rb +++ b/lib/chef/knife/download.rb @@ -48,7 +48,9 @@ class Chef error = false pattern_args.each do |pattern| - error ||= Chef::ChefFS::FileSystem.copy_to(pattern, chef_fs, local_fs, config[:recurse] ? nil : 1, config, ui, proc { |entry| format_path(entry) }) + if Chef::ChefFS::FileSystem.copy_to(pattern, chef_fs, local_fs, config[:recurse] ? nil : 1, config, ui, proc { |entry| format_path(entry) }) + error = true + end end if error exit 1 |