From a2deff1d21db69c85c80eaa9932979fd3b77a702 Mon Sep 17 00:00:00 2001 From: Tiago Carvalho Date: Fri, 5 Jul 2024 19:40:09 +0100 Subject: [PATCH 1/3] fmt check --- Justfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Justfile b/Justfile index 29adb8b..0a38bcf 100644 --- a/Justfile +++ b/Justfile @@ -6,8 +6,8 @@ help: clean: cargo clean -fmt: - cargo {{nightly_version}} fmt --all +fmt *CHECK: + cargo {{nightly_version}} fmt --all {{ if CHECK == "check" { "-- --check" } else { "" } }} clippy: cargo {{nightly_version}} clippy @@ -22,4 +22,4 @@ build: cargo build build-release: - cargo build --release \ No newline at end of file + cargo build --release From 3c0f1445a2051deb53cd50b14366603f2561a144 Mon Sep 17 00:00:00 2001 From: Tiago Carvalho Date: Fri, 5 Jul 2024 19:41:11 +0100 Subject: [PATCH 2/3] trigger fmt check in ci --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 94e9f79..f8f7b9e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -65,7 +65,7 @@ jobs: toolchain: nightly-2024-05-15 components: rustfmt cache: true - - run: just fmt + - run: just fmt check build: if: ${{ github.event_name == 'pull_request' }} From 8a38c915669b88ce7f7b702be0023c68bc651a22 Mon Sep 17 00:00:00 2001 From: Tiago Carvalho Date: Fri, 5 Jul 2024 19:48:15 +0100 Subject: [PATCH 3/3] fmt justfile and fix help msg --- Justfile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Justfile b/Justfile index 0a38bcf..ea4a45e 100644 --- a/Justfile +++ b/Justfile @@ -1,19 +1,19 @@ nightly_version := prepend('+', `cat rust-nightly-version`) help: - @echo fmt, clippy, clippy-fix, check or clean + @echo Available commands: `just --summary` clean: cargo clean fmt *CHECK: - cargo {{nightly_version}} fmt --all {{ if CHECK == "check" { "-- --check" } else { "" } }} + cargo {{ nightly_version }} fmt --all {{ if CHECK == "check" { "-- --check" } else { "" } }} clippy: - cargo {{nightly_version}} clippy + cargo {{ nightly_version }} clippy clippy-fix: - cargo {{nightly_version}} clippy --fix --allow-dirty --allow-staged + cargo {{ nightly_version }} clippy --fix --allow-dirty --allow-staged check: cargo check