Getting Started

Getting Started

Install Serez Code, write your first script, and get comfortable with the tools. Current version: v3.5.2

Installation

Windows

Download from GitHub Releases:

macOS

chmod +x sz-macos-arm64
mv sz-macos-arm64 /usr/local/bin/sz

Linux

chmod +x sz-linux-x64
mv sz-linux-x64 /usr/local/bin/sz

From source

Requires Rust stable:

git clone https://github.com/Sergio3215/serez-code
cd serez-code
cargo build --release

Verify

sz --version

All assets for v3.5.2 on GitHub →

Your first script

Create a file called hello.sz:

let name = "Serez"
out "Hello from {name}!"

let nums = [1, 2, 3, 4, 5]
let sum = nums.reduce(0, (acc, x) => acc + x)
out "Sum: {sum}"   // → Sum: 15

Run it:

sz hello.sz
Note: Use out to print values. Expressions are not auto-printed when running a file — only in the REPL.

The REPL

Run sz with no arguments. Results are printed automatically:

sz
>> let x = 10
>> x * 3
30
>> "hello".toUpperCase()
HELLO

CLI commands

CommandWhat it does
sz script.szRun a script file
szStart the interactive REPL
sz --watch script.szRe-run automatically on every save
sz --check script.szAnalyze estimated memory usage without running
sz --versionPrint the installed version
sz install <name>Install a package into ./packages/
sz uninstall <name>Remove an installed package

Watch mode

sz --watch main.sz

Memory check mode

sz --check script.sz

Function 'fibonacci': ~312 estimated bytes
  Criticality: ██  🟢 < 1KB (Safe)

Function 'processData': ~11840 estimated bytes
  Criticality: ██████████  🔴 > 10KB (Critical)