diff --git a/.github/workflows/rust-ci.yml b/.github/workflows/rust-ci.yml index 059fb67..bc162eb 100644 --- a/.github/workflows/rust-ci.yml +++ b/.github/workflows/rust-ci.yml @@ -25,6 +25,15 @@ jobs: - uses: dtolnay/rust-toolchain@stable - name: cargo fmt run: cargo fmt + fmt-nightly: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: dtolnay/rust-toolchain@nightly + with: + components: rustfmt + - name: cargo +nightly fmt + run: cargo +nightly fmt test: runs-on: ubuntu-latest steps: diff --git a/rustfmt.toml b/rustfmt.toml new file mode 100644 index 0000000..5cacac1 --- /dev/null +++ b/rustfmt.toml @@ -0,0 +1,4 @@ +unstable_features = true +imports_granularity = "Crate" +group_imports = "One" +format_code_in_doc_comments = true