How to install command line tools on OSX Mavericks

Kirill picture Kirill · Aug 13, 2013 · Viewed 40.7k times · Source

I am running OSX Mavericks (10.9) and while trying to update a bundle in rails, I get the following error message:

"You have to install development tools first."

I have Xcode already installed and there seems to be no option to install the tools from within the Xcode 4.6. How can I download and install command line tools via terminal?

Answer

Kirill picture Kirill · Aug 13, 2013

Incase, while trying to update a bundle, you get an error "You have to install development tools first." on OSX Mavericks (OSX 10.9), but you already have Xcode installed, you can still manually install the dev tools via terminal:

xcode-select --install

Do that and follow on-screen instructions. Your problem will be solved.