Skip to content

Commit

Permalink
Merge pull request #1454 from yelsa/fix-brew-force-flag
Browse files Browse the repository at this point in the history
brew_installer: fix use of force flag
  • Loading branch information
MikeMcQuaid authored Sep 30, 2024
2 parents ea9d90e + 0127d30 commit 849bcf9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/bundle/brew_installer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ def self.preinstall(name, no_upgrade: false, verbose: false, **options)
new(name, options).preinstall(no_upgrade:, verbose:)
end

def self.install(name, preinstall: true, no_upgrade: false, verbose: false, **options)
new(name, options).install(preinstall:, no_upgrade:, verbose:)
def self.install(name, preinstall: true, no_upgrade: false, verbose: false, force: false, **options)
new(name, options).install(preinstall:, no_upgrade:, verbose:, force:)
end

def initialize(name, options = {})
Expand Down Expand Up @@ -112,7 +112,7 @@ def link_change_state!(verbose: false, force: false)
when nil
if unlinked_and_not_keg_only?
puts "Linking #{@name} formula." if verbose
link_args = "link"
link_args = ["link"]
link_args << "--overwrite" if force
Bundle.system(HOMEBREW_BREW_FILE, *link_args, @name, verbose:)
elsif linked_and_keg_only?
Expand Down

0 comments on commit 849bcf9

Please sign in to comment.