Skip to content
LexerLangv0.2.0

Installing

A single binary for Windows, macOS and Linux; install script and manual setup.

LexerLang is a single binary. You do not need a runtime, a virtual machine or a package manager: downloading the file and putting it on your PATH is enough.

macOS and Linux#

Terminal
curl -fsSL https://lexer.gurerlabs.com/install.sh | sh

The script detects your operating system and architecture, downloads the right archive, verifies its SHA-256 checksum and installs the binary to ~/.local/bin/lexer. It does not ask for administrator rights.

To change the install directory:

Terminal
curl -fsSL https://lexer.gurerlabs.com/install.sh | LEXER_DIR=/usr/local/bin sh

For a specific version:

Terminal
curl -fsSL https://lexer.gurerlabs.com/install.sh | LEXER_VERSION=0.2.0 sh

PATH#

If ~/.local/bin is not on your PATH, the script says so. Add it to your shell's startup file:

Terminal
export PATH="$HOME/.local/bin:$PATH"

That file is ~/.zshrc (the macOS default), ~/.bashrc or ~/.profile. Open a new terminal afterwards.

Windows#

In PowerShell:

PowerShell
irm https://lexer.gurerlabs.com/install.ps1 | iex

The binary is installed to %LOCALAPPDATA%\LexerLang\bin\lexer.exe and that directory is added to your user PATH. No administrator rights are needed.

Once it finishes, restart any other open terminals: a PATH change only reaches newly started processes.

Manual installation#

The download page lists every platform's archive, size and SHA-256 checksum.

Terminal
# example: Linux, x86-64
curl -fsSL -o lexer-0.2.0-linux-amd64.tar.gz https://downloads.gurerlabs.com/lexer/linux-amd64/0.2.0
curl -fsSL -o SHA256SUMS https://downloads.gurerlabs.com/lexer/sha256/0.2.0

shasum -a 256 -c SHA256SUMS --ignore-missing

tar xzf lexer-0.2.0-linux-amd64.tar.gz
install -m 755 lexer ~/.local/bin/lexer

The archive contains one file: lexer (lexer.exe on Windows).

Binaries are built statically (CGO_ENABLED=0), so the glibc version does not matter; the same file runs on musl-based distributions such as Alpine.

Which archive#

PlatformArchiveAddress
macOS, Apple Siliconlexer-<version>-darwin-arm64.tar.gzmacos-arm64
macOS, Intellexer-<version>-darwin-amd64.tar.gzmacos-amd64
Linux, x86-64lexer-<version>-linux-amd64.tar.gzlinux-amd64
Linux, ARM64lexer-<version>-linux-arm64.tar.gzlinux-arm64
Windows, x86-64lexer-<version>-windows-amd64.zipwindows-amd64
Windows, ARM64lexer-<version>-windows-arm64.zipwindows-arm64

The download address is https://downloads.gurerlabs.com/lexer/<address>/<version>; latest instead of a version gives the latest stable release. If you are unsure of your architecture: uname -m on macOS and Linux, $env:PROCESSOR_ARCHITECTURE on Windows.

Building from source#

With Go 1.26 and make:

Terminal
cd bin-proj
make build
./bin/lexer version

External dependencies are two database drivers (pgx, go-sql-driver/mysql), golang.org/x/crypto and the embedded NarDB engine. NarDB is wired in through a local replace in go.mod, so building from source needs the NarDB repository at ../depo_app/nardb. All pure Go — no C toolchain required.

During development, to link the binary onto your PATH from the repository root:

Terminal
make lexer-enabled      # builds and links ~/.local/bin/lexer
make lexer-rebuild      # rebuilds, keeps the link
make lexer-status       # installation + running servers

It creates a symlink rather than a copy, so rebuilding also updates the command.

Updating#

Terminal
lexer update lexer@latest

Downloads the latest release, checks its SHA-256 against the release manifest, runs the new binary once to ask its version, and only then puts it in place of the old one. If the checksum does not match, nothing changes.

CallWhat it does
lexer updatesame as lexer@latest
lexer update lexer@0.2.0switches to a specific version (also to go back)
lexer update --checkonly reports whether a newer version exists

Running lexer serve processes keep the old version; restart them after updating. A development link created with make lexer-enabled is not updated — use make lexer-rebuild there. Without write access to the install directory, use sudo lexer update.

Verifying#

Terminal
lexer version
Output
lexer 0.2.0

For detailed output use lexer version --full: it also prints the commit, build date and runtime version.

Next#

Your first server — a ten-line file and lexer serve.