Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/autoproj/cli/update.rb
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,8 @@ def run(selected_packages, run_hook: false, report: true, ask: false, **options)
ws.finalize_setup
ws.export_installation_manifest

if options[:osdeps] && !osdep_packages.empty?
ws.install_os_repositories
if options[:osdeps]
ws.install_os_repositories unless osdep_packages.empty?
ws.install_os_packages(osdep_packages, **osdeps_options)
end

Expand Down
2 changes: 1 addition & 1 deletion lib/autoproj/os_package_installer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ def resolve_managers_dependencies(partitioned_packages)
# Requests the installation of the given set of packages
def install(
osdep_packages, all: nil, install_only: false,
run_package_managers_without_packages: false, **options
run_package_managers_without_packages: true, **options
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree. It feels like this is duplicated with the call_while_empty? flag. I'm guessing it was two attempts at fixing the same issue.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wanna remove it or keep it for backwards compatibility (although this is a "very" private API...)?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm good with removing it.

)
setup_package_managers(**options)
partitioned_packages =
Expand Down
6 changes: 3 additions & 3 deletions lib/autoproj/package_managers/bundler_manager.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def self.with_prerelease(*value)

# (see Manager#call_while_empty?)
def call_while_empty?
!workspace_configuration_gemfiles.empty?
true
end

# (see Manager#strict?)
Expand Down Expand Up @@ -550,13 +550,13 @@ def install(gems, filter_uptodate_packages: false, install_only: false)
File.read(gemfile_path) != gemfile_contents)
if updated
Ops.atomic_write(gemfile_path) do |io|
io.puts gemfile_contents
io.write gemfile_contents
end
end

options = []
binstubs_path = File.join(root_dir, "bin")
if updated || !install_only || !File.file?("#{gemfile_path}.lock")
if updated || !File.file?("#{gemfile_path}.lock")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand this one

"install_only" means "do not update". We are already checking if the gemfile got updated and run unconditionally, I don't understand why !install_only was removed.

Copy link
Contributor Author

@g-arjones g-arjones Nov 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm... I'm gonna have to go back to it. It's been a while (should have put a comment)

self.class.run_bundler_install(ws, gemfile_path, *options,
binstubs: binstubs_path)
end
Expand Down
Loading