From 006f2cdbf9fa32c2c3dd535771f448b8286ef45e Mon Sep 17 00:00:00 2001 From: Brandon Largeau Date: Mon, 30 Sep 2024 03:59:27 +0200 Subject: [PATCH] fix(just): use `powershell` compatible env variable for `doc` command (#6168) Hello, I was following the guide https://oxc.rs/docs/contribute/development.html and executed `just ready` as said. I got an error on Windows on the `doc` command because it sets the env variable in a way that is not compatible with `powershell`. I've used [attributes](https://just.systems/man/en/attributes.html#attributes) to fix the issue. I never used `just` so I don't know if there's a better way to fix the issue. --- justfile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/justfile b/justfile index 56a279f5a..59af22bcb 100755 --- a/justfile +++ b/justfile @@ -76,9 +76,14 @@ test: lint: cargo lint -- --deny warnings +[unix] doc: RUSTDOCFLAGS='-D warnings' cargo doc --no-deps --document-private-items +[windows] +doc: + $Env:RUSTDOCFLAGS='-D warnings'; cargo doc --no-deps --document-private-items + # Fix all auto-fixable format and lint issues. Make sure your working tree is clean first. fix: cargo clippy --fix --allow-staged --no-deps