diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 8f424e08c..0dd9d5c09 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -19,6 +19,9 @@ jobs: run: cargo build - name: check format run: PATH="target/debug:$PATH" build_tools/style.fish --all --check + - name: check rustfmt + run: find build.rs crates src -type f -name '*.rs' | xargs rustfmt --check + clippy: runs-on: ubuntu-latest diff --git a/.rustfmt.toml b/.rustfmt.toml index f3e454b61..f216078d9 100644 --- a/.rustfmt.toml +++ b/.rustfmt.toml @@ -1,2 +1 @@ edition = "2024" -style_edition = "2024" diff --git a/build_tools/style.fish b/build_tools/style.fish index 0cc612bf5..f26305f20 100755 --- a/build_tools/style.fish +++ b/build_tools/style.fish @@ -101,6 +101,10 @@ if test $all = yes; or set -q rust_files[1] exit 127 end + set -l edition_spec string match -r '^edition\s*=.*' + test "$($edition_spec