- Install Mono
- Also available through Homebrew
brew install mono
- Install Visual Studio Code
- Also available through Homebrew Cask
brew cask install visual-studio-code - Install
codecommand in terminal following these instructions
- Install .NET Core
- If using zsh/oh-my-zsh there is one documented extra step
- tl;dr
ln -s /usr/local/share/dotnet/dotnet /usr/local/bin
- tl;dr
- Install Node.js
- preferably through nvm
brew install nvm- Add this to either your
~/.bash_profileor~./zshrcthen restart terminal
export NVM_DIR="$HOME/.nvm" . "$(brew --prefix nvm)/nvm.sh"
nvm install stable
- Install JavaScript dependencies
npm install -g yo bower grunt-cli gulp generator-aspnet
- Create a new file from your terminal
code hello.cs
using System;
public class Program
{
public static void Main()
{
Console.WriteLine("Hello World");
}
}- Save the file and open your terminal.
- Run
mcs hello.csthenmono hello.exe - Verify file ran
Hello World!