lib/autobuild/importer.rb in autobuild-1.7.10 vs lib/autobuild/importer.rb in autobuild-1.7.11.rc1
- old
+ new
@@ -117,21 +117,21 @@
patches.map do |path, level|
[path, level, File.read(path)]
end
end
- def perform_update(package)
+ def perform_update(package,only_local=false)
cur_patches = currently_applied_patches(package)
needed_patches = self.patches
if cur_patches.map(&:last) != needed_patches.map(&:last)
patch(package, [])
end
retry_count = 0
package.progress_start "updating %s"
begin
- update(package)
+ update(package,only_local)
rescue Interrupt
raise
rescue ::Exception => original_error
# If the package is patched, it might be that the update
# failed because we needed to unpatch first. Try it out
@@ -144,11 +144,11 @@
if !cur_patches.empty?
package.progress_done
package.message "update failed and some patches are applied, retrying after removing all patches first"
begin
patch(package, [])
- return perform_update(package)
+ return perform_update(package,only_local)
rescue Interrupt
raise
rescue ::Exception
raise original_error
end
@@ -202,15 +202,15 @@
FileUtils.rm_rf package.importdir
fallback(e, package, :import, package)
end
# Performs the import of +package+
- def import(package)
+ def import(package,only_local = false)
importdir = package.importdir
if File.directory?(importdir)
package.isolate_errors(false) do
if package.update?
- perform_update(package)
+ perform_update(package,only_local)
else
if Autobuild.verbose
package.message "%s: not updating"
end
return