Installation

Get Nostos running on your machine in minutes. Choose your platform below.

macOS (Homebrew) - Recommended

The easiest way to install on macOS:

brew tap pegesund/nostos
brew install nostos

# Verify installation
nostos --version

macOS (Manual Download)

If you don't use Homebrew:

# For Apple Silicon (M1/M2/M3/M4)
curl -LO https://github.com/pegesund/nostos/releases/latest/download/nostos-aarch64-apple-darwin.tar.gz
tar -xzf nostos-aarch64-apple-darwin.tar.gz

# For Intel Mac
curl -LO https://github.com/pegesund/nostos/releases/latest/download/nostos-x86_64-apple-darwin.tar.gz
tar -xzf nostos-x86_64-apple-darwin.tar.gz

# Make executable and move to PATH
chmod +x nostos nostos-lsp
sudo mv nostos nostos-lsp /usr/local/bin/

macOS Security Note

macOS may block the binary because it's from an "unidentified developer". To fix this:

  1. Try to run nostos --version
  2. When blocked, go to System Preferences → Security & Privacy
  3. Click "Allow Anyway" next to the nostos message
  4. Or run: xattr -d com.apple.quarantine nostos

Linux

# Download the latest release
curl -LO https://github.com/pegesund/nostos/releases/latest/download/nostos-x86_64-unknown-linux-gnu.tar.gz

# Extract
tar -xzf nostos-x86_64-unknown-linux-gnu.tar.gz

# Make executable and move to PATH
chmod +x nostos nostos-lsp
sudo mv nostos nostos-lsp /usr/local/bin/

# Verify installation
nostos --version

Windows

Download from GitHub or use PowerShell:

# Download with PowerShell
Invoke-WebRequest -Uri "https://github.com/pegesund/nostos/releases/latest/download/nostos-x86_64-pc-windows-msvc.zip" -OutFile "nostos.zip"

# Extract
Expand-Archive -Path "nostos.zip" -DestinationPath "C:\nostos"

# Add to PATH (run as Administrator)
[Environment]::SetEnvironmentVariable("Path", $env:Path + ";C:\nostos", "Machine")

# Verify (open new terminal)
nostos --version

Or download the ZIP manually from GitHub Releases.

First Run

On first run, Nostos extracts its standard library and builds a bytecode cache:

$ nostos --version
Extracting stdlib to /home/user/.nostos/stdlib...
Stdlib extracted successfully.
Building bytecode cache for fast startup...
Cache built successfully.
nostos 0.2.0

This takes about 1-2 seconds. Subsequent runs start in ~0.1 seconds.

Hello, World!

Create your first Nostos program:

# Create a file
echo 'main() = println("Hello, Nostos!")' > hello.nos

# Run it
nostos hello.nos

Output:

Hello, Nostos!

Interactive REPL

Start the interactive environment:

nostos repl

Or use the TUI (Terminal User Interface) with editor, file browser, and more:

nostos tui

VS Code Extension

Get syntax highlighting, error checking, and autocomplete in VS Code:

Prerequisite

The extension requires nostos-lsp to be installed. This binary is included in the Nostos release packages. Make sure both nostos and nostos-lsp are in your PATH (e.g., in /usr/local/bin/).

# Download and install
curl -LO https://github.com/pegesund/nostos/releases/latest/download/nostos-vscode.vsix
code --install-extension nostos-vscode.vsix

Or download the .vsix file from GitHub Releases and install via:

VS Code → Extensions → ⋯ menu → Install from VSIX...

Features

  • Syntax highlighting
  • Real-time error checking (LSP)
  • Autocomplete for functions and types
  • Go to definition
  • Hover documentation

Next Steps

You're ready to start learning Nostos! Continue to the next chapter to learn the basics.