![fix brew cask fix brew cask](https://aral.github.io/fork-me-on-github-retina-ribbons/right-grey@2x.png)
Please check your brew install with brew doctor, it will probably tell you that you should consider updating your paths in ~/.bashrc. If this is not the case you’d probably end up not using brewed python. # /usr/local/bin should appear in front of /usr/bin because of missing permissions, then you’re doing it wrong! Also, don’t be afraid of multiple pythons on your system: you have them anyhow (python2 and python3) and it’s an advantage, as we’ll make sure that nothing poisons your system python and that you as a user & developer will use the brewed python: hash -r python # invalidate bash's lookup cache for python This also means that pip by default will work without sudo as all of homebrew, so if you ever run or have to run sudo pip. It’s more up to date than the system python, it will come with pip and correctly install in the brew directories, working together well with brewed python libs that aren’t installable with plain pip.
![fix brew cask fix brew cask](https://www.howtogeek.com/wp-content/uploads/2015/03/brew-doctor.png)
#brew install python3 # repeat/replace the following pip commands with pip3Ī word about brewed python: this is what you want!
![fix brew cask fix brew cask](https://user-images.githubusercontent.com/2316604/73780096-b2b76b00-4742-11ea-8491-43ef37d44296.png)
# and/or if you want to give python3 a go (it's about time): # set up some taps and update brewīrew tap homebrew/science # a lot of cool formulae for scientific toolsīrew tap homebrew/python # numpy, scipy, matplotlib. In general: execute the following commands one line at a time and read the outputs! If you read some warnings about “keg-only” that’s fine, it just means that brew won’t “hide” your system’s stuff behind the stuff it installed itself so it doesn’t cause problems… brewed stuff will still use it. In this case i can only recommend a backup again). If you don’t have a clean install, some of the following steps might need minor additional attention (like changing permissions chmod, chown, chgrp or overwriting existing files in the linking step with brew link -overwrite package_that_failed. Needless to say: Make a backup (Timemachine)įollow their instructions, then come back here. openblas as Accelerate was fixed in OS X 10.9
#Fix brew cask mac os x#
It will probably also work in the following versions (if not, let me know in the comments).Īn older version of this setup guide can be found here: Scientific Python on Mac OS X 10.8 with homebrew, main changes: rename of a tap + changes wrt. This step-by-step installation guide to setup a scientific python environment has been tested on Mac OS X Mavericks 10.9 / Yosemite 10.10 / El Capitain 10.11 / Sierra 10.12. The advantages are that this stack will never conflict with your system’s core and homebrew opens up a whole new world of easy to access unix tools via a simple brew install.
#Fix brew cask how to#
So here I’ll briefly explain how to set-up a scientific python stack based on homebrew. Also many of the other guides aren’t very easy to extend in “but i also need that library”-cases. So why another one? Cause i found most of the other ways to lead to long-term maintenance debt that is unnecessary and can easily be avoided. There are (too) many guides out there about how to install Python on Mac OS X.