Mac OS X 10.10 Yosemite Quick Start XCode Command Line Tools
The Tutorial shows you How to Install XCode 6 and Enable the XCode Command Line Developer Tools for macOS 10.10 Yosemite.
Xcode 6 introduces a radically new way to design and build software. Swift is an innovative new programming language for Cocoa and Cocoa Touch and, when combined with Xcode tools, makes programming a delightfully live experience.

Install XCode 6+ for Mac 10.10 Yosemite
Open a Command Line Terminal Window
(Press “Enter” to Execute Commands)In case first see: Terminal QuickStart Guide.
Accept the XCode License.
sudo xcodebuild -license
After type “q” and “agree” to Accept the License!
Install XCode Command Line Developer Tools.
sudo xcode-select --install
After you’ll be Prompted about the XCode Command Line Developer Tools and XCode-Select Installation.
How to Getting-Started with MacPorts for Mac 10.10 Yosemite