Files
heartwood/build/rust-version
T
Fintan Halpenny 7dcfe45781 build: Dockerfile uses Rust version from rust-toolchain.toml
Instead of hardcoding the version of the Rust alpine file, introduce an `ARG` in
the `Dockerfile`. In `build/build`, we determine the version by inspecting
`rust-toolchain.toml`, and pass this value in. This ensures that the binaries
are built using the same toolchain that we develop with.
2025-05-30 11:17:39 +02:00

8 lines
185 B
Bash
Executable File

#!/bin/sh
if ! version=$(grep -m 1 -oP "channel\s*=\s*\K(.*)" rust-toolchain.toml); then
echo "fatal: no rust version found via rust-toolchain.toml" >&2 ; exit 1
fi
echo "$version"