From 2857c1277cb1365683322397b6abeab4113ddd01 Mon Sep 17 00:00:00 2001 From: Restioson Date: Wed, 26 Jul 2023 17:07:17 +0200 Subject: [PATCH] Allow setting RUST_LOG to any value in `just all` --- justfile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/justfile b/justfile index 2598ac2d9..c77afa1d2 100644 --- a/justfile +++ b/justfile @@ -39,12 +39,14 @@ deps-ios: cargo install cargo-lipo rustup target add aarch64-apple-ios x86_64-apple-ios +# RUST_LOG is overriden to "" here since FRB codegen panics if RUST_LOG isn't info or debug, which +# means a command like `RUST_LOG="warn" just all` would fail gen: #!/usr/bin/env bash set -euxo pipefail cd mobile flutter pub get - flutter_rust_bridge_codegen \ + RUST_LOG={{ if env_var("RUST_LOG") =~ "(?i)(trace)|(debug)" { "debug" } else { "info" } }} flutter_rust_bridge_codegen \ --rust-input native/src/api.rs \ --c-output ios/Runner/bridge_generated.h \ --extra-c-output-path macos/Runner/ \