bin/autoproj_bootstrap in autoproj-1.9.3.rc1 vs bin/autoproj_bootstrap in autoproj-1.9.3.rc2

- old
+ new

@@ -297,12 +297,12 @@ # Package manager interface for systems that use port (i.e. MacPorts/Darwin) as # their package manager class PortManager < ShellScriptManager def initialize super(['port'], true, - "port '%s'", - "port '%s'") + "port install '%s'", + "port install '%s'") end end # Package manager interface for systems that use pacman (i.e. arch) as # their package manager @@ -519,17 +519,11 @@ end if !installed.empty? && Autobuild.do_update # Look if we can update the package ... dep = Gem::Dependency.new(name, version_requirements) - available = - if gem_fetcher.respond_to?(:find_matching) - gem_fetcher.find_matching(dep, true, true, GemManager.with_prerelease) - else - dep.prerelease = GemManager.with_prerelease - gem_fetcher.search_for_dependency(dep).first - end + available = gem_fetcher.find_matching(dep, true, true, GemManager.with_prerelease) installed_version = installed.map(&:version).max available_version = available.map { |(name, v), source| v }.max if !available_version if version raise ConfigError.new, "cannot find any gem with the name '#{name}' and version #{version}" @@ -1702,9 +1696,17 @@ def self.in_autoproj_installation?(path) root_dir(File.expand_path(path)) true rescue UserError false + end + + # Forcefully sets the root directory + # + # This is mostly useful during bootstrapping (i.e. when the search would + # fail) + def self.root_dir=(dir) + @root_dir = dir end # Returns the root directory of the current autoproj installation. # # If the current directory is not in an autoproj installation,