From c30891de836912487c967a3a779ca6d352c71e38 Mon Sep 17 00:00:00 2001 From: AramJonghu Date: Sat, 16 May 2026 01:37:38 +0200 Subject: [PATCH] rustfmt w/o project --- .gitea/workflows/lint-rust.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/lint-rust.yml b/.gitea/workflows/lint-rust.yml index cd64d27..9db1d73 100644 --- a/.gitea/workflows/lint-rust.yml +++ b/.gitea/workflows/lint-rust.yml @@ -20,8 +20,10 @@ jobs: - name: Rustfmt run: | - if [ -f Cargo.toml ]; then - cargo fmt --check + if [ -n "$(find . -name "Cargo.toml" -print -quit)" ]; then + find . -name "Cargo.toml" -print0 | while IFS= read -r -d '' manifest; do + cargo fmt --check --manifest-path "$manifest" + done elif [ -n "$(find . -name "*.rs" -print -quit)" ]; then echo "Rust files found but no Cargo.toml" exit 1