about summary refs log tree commit diff
diff options
context:
space:
mode:
authorIlan Joselevich <personal@ilanjoselevich.com>2024-08-04T00·22+0300
committerclbot <clbot@tvl.fyi>2024-08-04T13·47+0000
commit26129c1761259290cf47de4358a90f3608fe83ae (patch)
treea5888be21e382430a4956dd1335333fa01838222
parent9c01ab3e841eb67d7d2b6efc7675040b646a7b76 (diff)
fix(tvix/crate2nix-check): Revert use of depotfmt.check wrapper r/8441
This is a partial revert of https://cl.tvl.fyi/c/depot/+/12068 where I
changed tvix/crate2nix-check to use depotfmt.check. It turns out that we
don't actually want to be using it in this case as the wrapper sets
`--fail-on-change` which would always fail because the Cargo.nix
generated by crate2nix will always need to be changed (It's not
formatted properly).

Change-Id: Ife35c812ca69c90459ce4445f4252d0a24c218fa
Reviewed-on: https://cl.tvl.fyi/c/depot/+/12132
Tested-by: BuildkiteCI
Autosubmit: Ilan Joselevich <personal@ilanjoselevich.com>
Reviewed-by: flokli <flokli@flokli.de>
-rw-r--r--tvix/default.nix7
1 files changed, 5 insertions, 2 deletions
diff --git a/tvix/default.nix b/tvix/default.nix
index 0d833eb1e50a..f8aa47a108c5 100644
--- a/tvix/default.nix
+++ b/tvix/default.nix
@@ -73,8 +73,11 @@ in
         cargo metadata > /dev/null
 
         ${pkgs.crate2nix}/bin/crate2nix generate --all-features
-        # Reuse depotfmt wrapper that can be used inside a sandbox.
-        ${depot.tools.depotfmt.check} Cargo.nix
+        ${pkgs.treefmt}/bin/treefmt Cargo.nix \
+          --no-cache \
+          --on-unmatched=debug \
+          --config-file=${depot.tools.depotfmt.config} \
+          --tree-root=.
 
         # technically unnecessary, but provides more-helpful output in case of error
         diff -ur Cargo.nix ${src}/Cargo.nix