Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: How to force overwrite without forcing reinstall? #23587

Closed
pftbest opened this issue Aug 10, 2016 · 1 comment
Closed

Question: How to force overwrite without forcing reinstall? #23587

pftbest opened this issue Aug 10, 2016 · 1 comment

Comments

@pftbest
Copy link

pftbest commented Aug 10, 2016

For a while I was using this script to update my casks:

for i in $(brew cask list); do brew cask install $i; done

And it worked great (except for chromium), when cask was up to date it just printed Warning: A Cask for ... is already installed... and when it needed updating it installed a new version.

But now with this new move semantics it does things like this:

==> Downloading http://download.qt.io/official_releases/qtcreator/4.0/4.0.3/qt-c
######################################################################## 100.0%
==> Verifying checksum for Cask qt-creator
==> It seems there is already an App at '/Applications/Qt Creator.app'; not movi
🍺  qt-creator was successfully installed!

and I still get the old version, even though it says "successfully installed!"
I know I can use --force to force overwrite, but I can't use it my script because it will force reinstall on casks that do not need updating. So my question is, how do I force overwrite, without forcing reinstall of up-to-date casks, or how do I get a list of casks that need updating, so I could use --force on them?

@vitorgalvao
Copy link
Member

brew cask list is broken, and you cannot rely on it. There is no official way to upgrade casks yet, and not method is support or encouraged by us. Whatever works for you is fine, but we won’t encourage any particular way.

Also, the successfully installed! message is definitely a bug.

@Homebrew Homebrew locked and limited conversation to collaborators May 9, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants