-
Rust Toolchain: You need the
rusttoolchain corresponding torust-toochain.mdinstalled. Install Rust withrust-upand anycargoinvocations will then automatically respect the toolchain. -
Command runner
just. -
The Cargo plugin
cargo-watchfor continuous building. -
Container manager such as
podman,dockerfor some tooling (formatting etc.).
If you have the package manager
nix installed you can
enter a development setup easily with
nix ./tools/nix#defaultor just nix-develop or automatically when direnv is
installed and setup for your shell and
direnv allow was executed inside the repository.
Note: Make sure to enable flakes and nix-command in
your nix config
To format the whole project run
just formatNote: If you use docker, use just container_mgr=docker format
To build the tool with cargo run
just buildand for continuous building (needs):
just watchTo run the tests do
just testTo build the package with Nix run:b
just nix-packageTo build the image with Nix run:
just nix-imageCI is run with some container images which can be updated with:
just upload-ci-images [<version>] [<registry>]where the <version> should be a semantic version. Note: By default it will
upload and overwrite the current version.
To prepare a release you can execute:
just release <sem-version>It will:
-
Check that the version is semantic version and the version does not exists (local and remote) and it is newer then all remote version.
-
Update the
Cargo.tomland make a commit onmain. -
Push a prepare tag
prepare-v<version>which triggers therelease.yamlpipeline.
Note: If the release pipeline fails, you can just run this same command again.
Also rerun it when you made a mistake, it will cancel the current release (works
also when --amending on the current commit)
A benchmarking script is provided in tools/bench/benchmark.sh, along with a
nix devshell. To run the benchmark in the isolated environment, run:
just nix-develop-bench bash ./tools/bench/benchmark.sh