Cocoapod install does not add to PATH
Question
I installed cocoapods on OSX 10.9.3 Mavericks.
The installation finished fine, but I cannot run the pod update command. as nothing was added to my PATH. I am trying to find the /usr/local/Cellar/ruby folder to find the pod file to put in my PATH, but no such folder exists.
Where is the cocoapod file installed, and what I need to add in my PATH to make it work?
Solution
Cocoapods is installed using Ruby Gems. If you do not have a previous Ruby installation, you can go ahead and install using SUDO, which will use the OSX system default Ruby installation. But if you have a local version of Ruby already running for whatever reason, using SUDO will not work as the pod binary will be installed in the System default Ruby folder instead of the local version where it should be really installed for all the PATH and environment variable to work correctly. Just using gem install should work in this case.
If you have a local version of ruby rvm
gem install cocoapods
instead of
sudo gem install cocoapods