class Chef::Knife::Upload

def run

def run
  if name_args.length == 0
    show_usage
    ui.fatal("You must specify at least one argument. If you want to upload everything in this directory, run \"knife upload .\"")
    exit 1
  end
  error = false
  pattern_args.each do |pattern|
    fs_error, result = Chef::ChefFS::FileSystem.copy_to(pattern, local_fs, chef_fs, config[:recurse] ? nil : 1, config, ui, proc { |entry| format_path(entry) })
    if fs_error
      error = true
    end
  end
  if error
    exit 1
  end
end