Last Updated: February 25, 2016
· fsproru
Bg black crop

From MacPorts to Homebrew

Here is my experience with transition from MacPorts to Homebrew

RVM and Macports

Uninstall installed ports and remove MacPorts files (following official guide http://guide.macports.org/#installing.macports.uninstalling)

sudo port -fp uninstall installed
sudo rm -rf \
    /opt/local \
    /Applications/DarwinPorts \
    /Applications/MacPorts \
    /Library/LaunchDaemons/org.macports.* \
    /Library/Receipts/DarwinPorts*.pkg \
    /Library/Receipts/MacPorts*.pkg \
    /Library/StartupItems/DarwinPortsStartup \
    /Library/Tcl/darwinports1.0 \
    /Library/Tcl/macports1.0 \

Remove /opt/local from you PATH in your .zshrc or .bashrc

export PATH=/opt/local/bin:/opt/local/sbin:$PATH # delete this

Reinstall missing packages (that used to be installed from MacPorts) using brew. For example:

brew install wget coreutils

Delete old gemsets, reinstall rubies and gems using RVM. For ex:

rvm gemset delete <your_gemset>
rvm uninstall <your_ruby>
rvm install <your_ruby>
rvm use --create <your_ruby>@<your_gemset>
bundle install # or gem install <your_gems>
Say Thanks