summaryrefslogtreecommitdiff
path: root/lib/chef/knife/upload.rb
diff options
context:
space:
mode:
authorJohn Keiser <jkeiser@opscode.com>2013-05-19 10:02:13 -0700
committerJohn Keiser <jkeiser@opscode.com>2013-06-07 13:12:33 -0700
commitead004dc367ca9cb62cbe259f4f456e286c5f35c (patch)
treebbbf9a6d6bc2df788ed5be7939106a9e8fe31afd /lib/chef/knife/upload.rb
parent421fea23afaed6eddd76654757b25c88c49808a6 (diff)
downloadchef-ead004dc367ca9cb62cbe259f4f456e286c5f35c.tar.gz
Fix bug where we didn't go through all patterns if the first one failed
Diffstat (limited to 'lib/chef/knife/upload.rb')
-rw-r--r--lib/chef/knife/upload.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/chef/knife/upload.rb b/lib/chef/knife/upload.rb
index 7105945a96..8bc3f411ff 100644
--- a/lib/chef/knife/upload.rb
+++ b/lib/chef/knife/upload.rb
@@ -48,7 +48,9 @@ class Chef
error = false
pattern_args.each do |pattern|
- error ||= Chef::ChefFS::FileSystem.copy_to(pattern, local_fs, chef_fs, config[:recurse] ? nil : 1, config, ui, proc { |entry| format_path(entry) })
+ if Chef::ChefFS::FileSystem.copy_to(pattern, local_fs, chef_fs, config[:recurse] ? nil : 1, config, ui, proc { |entry| format_path(entry) })
+ error = true
+ end
end
if error
exit 1