RivetScript is a backend/system-oriented language with JS-adjacent syntax and safer defaults ("rivet" mode).
This repo hosts the Rust stage-0 compiler (rsc), runtime VM, and the forger project runner.
cargo run -- run examples/hello.rvt
cargo run -p forger -- rungit clone https://github.com/vspcoderz/revitscript.git
cd rivetscript/rivet
cargo build --release -p compiler -p forger
export PATH="$PWD/target/release:$PATH"Release binaries live in dist/ after running the scripts below. Attach them to your GitHub release for distribution.
./scripts/build-release.shWindows PowerShell:
./scripts/build-release.ps1docs.md(learning-focused guide: architecture, bytecode, runtime, CLI)learn.md(syntax primer for developers)version.jsoncontrols automatic release tagging (+ release notes) when pushed tomain
- Bash:
./scripts/install.sh [dest]downloads the latest Linux/macOS tarball, extractsrsc/forger, and installs them into/usr/local/binor thedestyou pass. - PowerShell:
./scripts/install.ps1 [-InstallDir <path>]grabs the Windows ZIP release, extractsrsc.exe/forger.exe, and copies them into something likeC:\Program Files\RivetScript(use-InstallDirfor a custom folder).
The manifest packs.json exposes named scripts—"run": "index.rvt" and "start": "index.rvt"—so forger run start is the same as forger run index.rvt and can power npm start–style launchers. Define more entries like "dev": "examples/service_router.rvt" whenever you need shorthand commands.
./scripts/build-release.shWindows:
./scripts/build-release.ps1rsc run <file>: compile and run.rvtor run.rsbc.rsc build <file> -o <out.rsbc>: emit bytecode.rsc test: run tests.forger run [script|file]: run frompacks.jsonorindex.rvt.forger build [file] -o <out.rsbc>: build from script or path.forger test: runscripts.testorrsc test.forger init: createpacks.jsonandindex.rvt.forger add <name@version>: add a dependency entry.