build: tidy up the Ambient plan

Signed-off-by: Lars Wirzenius <liw@liw.fi>
This commit is contained in:
Lars Wirzenius
2025-01-13 12:13:52 +02:00
parent ea0cb355ed
commit 7401ee6d08
+10 -12
View File
@@ -1,8 +1,14 @@
pre_plan:
- action: cargo_fetch
plan:
# - action: cargo_fmt
# - action: cargo_clippy
- action: cargo_fmt
- action: cargo_clippy
# Not using the built-on `cargo_test` action, as the test suite
# requires HOME to be set and Ambient doesn't yet have a way to do
# that. So we use the `shell` action instead, even if that is more
# tedious and requires setting up the relevant environment variables
# manually.
- action: shell
shell: |
export CARGO_TARGET_DIR=/workspace/cache
@@ -10,17 +16,9 @@ plan:
export HOME=/root
export PATH="/root/.cargo/bin:$PATH"
# Configure Git so that it can be used in the tests for this
# project.
git config --global user.email "test@example.com"
git config --global user.name "Testy McTestface"
env
ls -lA /root/.rustup/toolchains
command -v cargo
command -v rustc
rustup show
rustup toolchain list
rustc --version
cargo test
# - action: cargo_test