A Nix Flake for developing Zig.
- A Nix dev shell for building Zig from src
# Start dev shell nix develop .
- An opinionated script (
./run
) that helps with building and testing ZigGetting from zero to a self-built Zig is really fast:./run buildBootstrap # Build stage3 ./run usePrebuilt # Alternatively, use a signature-checked stage3 binary from ziglang.org ./run buildDebug # Use stage3 to create a Zig debug build ./run testBehavior # Run behavior tests for the debug build
./run usePrebuilt && ./run buildDebug
takes less than 3 minutes on an average desktop system. - Zig
master
pkgsnix build .#zig # Built from source nix build .#zigPrebuilt # Prebuilt static binary from ziglang.org
This repo is regularly updated to track Zig master
.
See ./usage.sh
on how to use this repo.
See ./dev/README.md
on how to develop and contribute to this repo.
zig-overlay, which packages the official prebuilt static Zig binaries with Nix.
zig2nix, Flake for packaging, building and running Zig projects.