Installation macOS - SkycoinWikis/CX GitHub Wiki

CX HOME » CX » GETTING STARTED » INSTALLATION MACOS

CX Installation on macOS

To install cx on macOS the best way is to use Homebrew.

  1. Homebrew Install

Homebrew-Install

  1. Make sure you have got Homebrew. If you haven't, you can download and install it by pressing + Space and typing in Terminal to start Terminal, then typing in the following command:
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)
  1. Press + Space and type in Terminal to start Terminal.

  2. Type in the following lines to install CX:

brew tap skycoin/homebrew-skycoin
brew install skycoin-cx
  1. To update use the following command:
brew update skycoin-cx

Hello, World!

To check our Installation with something more than a version output we will now make a cx-file to print out 'Hello World!'

  1. Make a new text-file and rename it to hello-world.cx

  2. Open the file with a text editor and type in the following:

    package main
    
    func main () {
         str.print("Hello, World!")
    }
  3. Save and close

  4. Press + Space and type in Terminal to start Terminal.

  5. Move to the direction where your hello-world.cx is and type in cx hello-world.cx or just drag and drop your file into the terminal after typing in cx followed by a Space

Next Step

The next step should be to search for a tool/development environment that fits you to code as easy as possible. Have a look into Programming Tools to find and setup your favorite Code Editor.

⚠️ **GitHub.com Fallback** ⚠️