I installed Homebrew Cask for kicks as described at http://caskroom.io/. It boils down to the following command:
$ brew install caskroom/cask/brew-cask
$ brew tap caskroom/versions
Homebrew Cask installed and everything was fine. Then I uninstalled Homebrew Cask like so:
$ brew untap caskroom/versions
$ brew uninstall brew-cask
Here are the current taps:
$ brew tap
homebrew/versions
Yet I see stuff from Cask when searching for items that wouldn't be part of Homebrew itself (like Graphical programs, aText, Fantastical etc.):
$ brew search atext
Caskroom/cask/atext
Though it doesn't install (as expected):
$ brew install atext
Error: No available formula for atext
Searching formulae...
Searching taps...
Caskroom/cask/atext
So the question is why does brew search Caskroom/cask and how do I get rid of it (I don't want Homebrew telling me it has aText, for example, when it can't install it)?
I am running Mac OS X Yosemite.
For the current version of Brew:
$ brew uninstall --cask yed
For older versions of Brew:
$ brew cask uninstall yed
the result:
==> Removing App symlink: '/Users/user/Applications/yEd.app'
As of Homebrew version 0.9.5, it appears that brew search will find items in Caskroom/cask/ without actually having Homebrew Cask installed. You can also install them, but this will actually install brew-cask as a dependency along the way.
Try:
brew install Caskroom/cask/atext
Command the terminal to "untap" at the prompt [MacOS Catalina 10.15.2]
Run
brew untap homebrew/cask-fonts
Expected output
Untapping homebrew/cask-fonts...
Untapped 1571 casks (1,713 files, 11.4MB)
Related
I have a Macbook Pro that has an M1 Chip that is causing issues trying to install Homebrew. I have followed the steps in this article: https://mac.install.guide/homebrew/3.html but when I get to the Homebrew install and I type brew in the terminal I get this
Example usage:
brew search TEXT|/REGEX/
brew info [FORMULA|CASK...]
brew install FORMULA|CASK...
brew update
brew upgrade [FORMULA|CASK...]
brew uninstall FORMULA|CASK...
brew list [FORMULA|CASK...]
Troubleshooting:
brew config
brew doctor
brew install --verbose --debug FORMULA|CASK
Contributing:
brew create URL [--no-fetch]
brew edit [FORMULA|CASK...]
Further help:
brew commands
brew help [COMMAND]
man brew
https://docs.brew.sh
Shouldn't it tell me what version of Homebrew I have and that it's installed?
I am trying to set up my Homebrew so that I can use it with git. I am trying to do brew install git and brew install git-lfs but I get the below error messages when I try to do that.
fatal: Could not resolve HEAD to a revision
Warning: No available formula with the name "git".
==> Searching for similarly named formulae...
Error: No similarly named formulae found.
==> Searching for a previously deleted formula (in the last month)...
Error: No previously deleted formula found.
==> Searching taps on GitHub...
Error: No formulae found in taps.
Shouldn't it tell me what version of Homebrew I have and that it's installed?
To find the installed version, use the -v option.
% brew -v
Homebrew 3.6.0
Homebrew/homebrew-core (git revision e5722d08e47; last commit 2022-09-09)
Homebrew/homebrew-cask (git revision 0dc06a0f09; last commit 2022-09-09)
fatal: Could not resolve HEAD to a revision
You will need to reinstall, and make sure it uses /opt/homebrew because you are on an M1.
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
There shouldn't be any errors displayed when this runs.
This is how to install Firefox via Homebrew:
brew install --cask firefox
But how to install the 'Firefox Developer edition'?
Everything I tried fails with 'Error: Cask '...' is unavailable: No Cask with this name exists.'
brew install --cask firefox-developer-edition
brew install --cask firefox-nightly
What's the correct command?
I've finally found a solution.
A lot of commands on the internet were outdated.
These 2 commands worked for me in 2022:
brew tap homebrew/cask-versions
brew install --cask firefox-developer-edition
Homebrew Structure Files
If we go to homebrew repo in our Mac: /usr/local/Homebrew/Library/Taps/homebrew we see some folder like homebrew-core, homebrew-cask, homebrew-cask-fonts these files are what we get when we run :
brew search [formula or cask name]
When we do brew tap homebrew/cask-versions the casks files are cloned to our Homebrew repo. Since that, you may install an alternate cask that was not found before.
For more information, you may found it here.
Trying to install brew-cask after tapping caskroom/cask,
brew tap caskroom/cask
brew install brew-cask
But getting error,
$ brew install brew-cask
Updating Homebrew...
Error: No available formula with the name "brew-cask"
==> Searching for a previously deleted formula (in the last month)...
Error: No previously deleted formula found.
==> Searching for similarly named formulae...
This similarly named formula was found:
brew-cask-completion ✔
To install it, run:
brew install brew-cask-completion ✔
==> Searching taps...
==> Searching taps on GitHub...
Error: No formulae found in taps.
Tried brew cleanup, untapped caskroom/cask and reinstallation of brew-cask but no luck.
I installed, brew-cask-completion using brew install brew-cask-completion. And read somewhere brew-cask is deprecated. So what is the solution. I ignored it and installed the java open sdk. My question is, is it going to be a problem in future if I don't install it?
Thanks in advance!
It happens because of corrupted core installation, actually you will give this error for installing any packages, you should fix the with:
rm -fr $(brew --repo homebrew/core)
Then install what ever you want, for me:
brew intall deno
Try reinstalling it with these commands in this order:
brew uninstall brew-cask
brew untap caskroom/cask
brew tap caskroom/cask
brew install brew-cask
I'm trying to install wxWidgets on Mac OS X 10.9. It's already installed, but I'm having the problem described here. Someone suggested to add ENV.append_to_cflags "-stdlib=libc++". I did, but I'm not able to recompile the code.
$ brew install wxmac
Warning: wxmac-3.0.0 already installed
$ brew edit wxmac
=> ok, modifications done, now I want to recompile and reinstall
$ brew uninstall wxmac
Uninstalling /usr/local/Cellar/wxmac/3.0.0...
$ brew install wxmac
==> Downloading https://downloads.sf.net/project/machomebrew/Bottles/wxmac- 3.0.0.mavericks.bottle.2.tar.gz
Already downloaded: /Library/Caches/Homebrew/wxmac-3.0.0.mavericks.bottle.2.tar.gz
==> Pouring wxmac-3.0.0.mavericks.bottle.2.tar.gz
🍺 /usr/local/Cellar/wxmac/3.0.0: 775 files, 41M
How can I force homebrew to recompile?
Homebrew is installing wxmac in bottle form (a pre-compiled binary of wxmac). To build from source, add the --build-from-source flag when calling brew install:
$ brew install --build-from-source wxmac
To rebuild all installed FORMULAE from source:
$ brew list | xargs brew reinstall --build-from-source
How do I update a formula?
I ran brew update. However, mongodb is still outdated according to brew outdated:
mongodb (1.4.3-x86_64 < 1.6.5-x86_64)
First, update brew's internal list of formulae to the latest:
brew update
To upgrade only the mongodb formula, use install:
brew install mongodb
To upgrade all outdated formulae:
brew upgrade
You can update all outdated packages like so:
brew install `brew outdated`
or
brew outdated | xargs brew install
or
brew upgrade
This is from the brew site..
for upgrading individual formula:
brew install formula-name && brew cleanup formula-name
You will first need to update the local formulas by doing
brew update
and then upgrade the package by doing
brew upgrade formula-name
An example would be if i wanted to upgrade mongodb, i would do something like this, assuming mongodb was already installed :
brew update && brew upgrade mongodb && brew cleanup mongodb
Well, I just did
brew install mongodb
and followed the instructions that were output to the STDOUT after it finished installing, and that seems to have worked just fine. I guess it kinda works just like make install and overwrites (upgrades) a previous install.
You can't use brew install to upgrade an installed formula. If you want upgrade all of outdated formulas, you can use the command below.
brew outdated | xargs brew upgrade
I prefer to upgrade all homebrew formulae and homebrew cask formulae.
I added a Bourne shell function to my environment for this one (I load a .bashrc)
function updatebrew() {
set -x;
brew update;
brew cleanup;
brew cask upgrade --greedy
)
}
set -x for transparency: So that the terminal outputs whatever Homebrew is doing in the background.
brew update to update homebrew formulas
brew cleanup to remove any change left over after installations
brew cask upgrade --greedy will install all casks; both those with versioning information and those without