Skip to content

Commit

Permalink
Merge pull request #10910 from Bo98/upgrade-dry-run
Browse files Browse the repository at this point in the history
cmd/upgrade: fix --dry-run
  • Loading branch information
Bo98 committed Mar 23, 2021
2 parents 3c6a7b3 + 3bf38a1 commit 52c6faf
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions Library/Homebrew/cmd/upgrade.rb
Original file line number Diff line number Diff line change
Expand Up @@ -174,19 +174,21 @@ def upgrade_outdated_formulae(formulae, args:)
puts formulae_upgrades.join("\n")
end

Upgrade.upgrade_formulae(
formulae_to_install,
flags: args.flags_only,
installed_on_request: args.named.present?,
force_bottle: args.force_bottle?,
build_from_source_formulae: args.build_from_source_formulae,
interactive: args.interactive?,
keep_tmp: args.keep_tmp?,
force: args.force?,
debug: args.debug?,
quiet: args.quiet?,
verbose: args.verbose?,
)
unless args.dry_run?
Upgrade.upgrade_formulae(
formulae_to_install,
flags: args.flags_only,
installed_on_request: args.named.present?,
force_bottle: args.force_bottle?,
build_from_source_formulae: args.build_from_source_formulae,
interactive: args.interactive?,
keep_tmp: args.keep_tmp?,
force: args.force?,
debug: args.debug?,
quiet: args.quiet?,
verbose: args.verbose?,
)
end

Upgrade.check_installed_dependents(
formulae_to_install,
Expand Down

0 comments on commit 52c6faf

Please sign in to comment.