Install Novis
Novis is one program, nvs. It checks, compiles, runs, tests and serves your code. You download
nvs or build it from source. Then you put it on your PATH.
The current release is 0.0.6. Novis is Pre-Alpha. Any release can change the
language, and Novis is not ready for production use.
Download a release
Section titled “Download a release”Each release has an archive of nvs for each platform:
- Linux, x86-64:
nvs-0.0.6-linux-x86_64.tar.gz - Linux, ARM64:
nvs-0.0.6-linux-aarch64.tar.gz - Windows, x86-64:
nvs-0.0.6-windows-x86_64.zip - macOS, Apple silicon:
nvs-0.0.6-macos-aarch64.tar.gz
The file SHA256SUMS has the checksum of each archive.
Check a release archive shows how to use it. The
release page lists every file of the release.
-
Download the archive for your platform, and unpack it. The archive has a folder with
nvsin it.Right-click the
.zipfile and choose Extract All.Terminal window tar -xzf nvs-0.0.6-linux-x86_64.tar.gzOn an ARM64 computer, use the file that ends in
linux-aarch64.tar.gz.Terminal window tar -xzf nvs-0.0.6-macos-aarch64.tar.gz -
Copy
nvsto a folder that is on yourPATH, as step 4 of Build from source shows. -
Check that it runs. The command prints the version of
nvs.Terminal window nvs --version
Install the VS Code extension
Section titled “Install the VS Code extension”The extension adds colours, errors and completion for .nvs files. It is in the
VS Code Marketplace. In VS Code,
open the Extensions view, search for Novis and install Novis-Lang. This command does the same
from a terminal:
code --install-extension novis-lang.nvsVSCodium, Cursor and some other editors install extensions from
Open VSX. The extension is there too. Search for
Novis in the Extensions view of your editor.
Each release also has the extension as a file: nvs-0.0.6.vsix.
This command installs the file you downloaded:
code --install-extension nvs-0.0.6.vsixInstall the extension shows both ways step by step.
Run Novis with Docker
Section titled “Run Novis with Docker”Each release also publishes an image with nvs in it:
docker pull ghcr.io/novis-lang/novis:0.0.6Docker shows how to serve an application with it.
What you need to build from source
Section titled “What you need to build from source”You need Rust, which you install with rustup. You do not need to choose a
Rust version. The repository has a file, rust-toolchain.toml, that names the version. rustup
installs that version the first time you build.
Some parts of the build compile C code, so you also need a C compiler:
Install the Visual Studio Build Tools with the workload Desktop development with C++. The
rustup installer offers to do this for you.
Install git and a C compiler. On Debian and Ubuntu, run sudo apt install git build-essential.
Install the Xcode command line tools with xcode-select --install. They include git and a C
compiler.
Build from source
Section titled “Build from source”-
Get the source code:
Terminal window git clone https://github.com/novis-lang/novis.git noviscd novis -
Build
nvs. This takes several minutes the first time.Terminal window cargo build --release -p nvs-cli -
Check that it runs. The command prints the version of
nvs.Terminal window .\target\release\nvs.exe --versionTerminal window ./target/release/nvs --versionTerminal window ./target/release/nvs --version -
Copy the program to a folder that is on your
PATH. Then you can typenvsin any folder.Copy
target\release\nvs.exeto a folder such asC:\Tools. Then add that folder to thePathvariable in Settings > System > About > Advanced system settings > Environment Variables.Terminal window sudo install -m 0755 target/release/nvs /usr/local/bin/nvsTerminal window sudo install -m 0755 target/release/nvs /usr/local/bin/nvs
Check a release archive
Section titled “Check a release archive”Each release has the file SHA256SUMS with the checksum of each archive. Each archive also has a
signed statement. It says that the release workflow of the Novis repository built the archive, and
from which commit.
These two commands check an archive. The first one needs the GitHub CLI, gh. Download
SHA256SUMS into the folder of the archive first.
gh attestation verify nvs-0.0.6-linux-x86_64.tar.gz --repo novis-lang/novissha256sum --check --ignore-missing SHA256SUMSThe first command checks the signed statement. The second command checks the archive against its
checksum in SHA256SUMS.
The commands you use first
Section titled “The commands you use first”| Command | What it does |
|---|---|
nvs run file.nvs |
checks a program, then compiles and runs it |
nvs check file.nvs |
checks a program and prints every error, without running it |
nvs test file.nvs |
runs the #[Test] methods in a program |
nvs serve file.nvs |
runs a web application until you stop it |
nvs fmt file.nvs |
rewrites a file in the standard layout |
nvs help <command> prints the help for one command.
Next steps
Section titled “Next steps”- Hello, World! is your first program.
- The editor extension adds colours, errors and completion to VS Code.
- Install on a server shows the folders and permissions a server needs.
- A Tour of Novis goes from Hello world to a running web application.
