From bad6165346f8b504662b3fa993791e9564a542cf Mon Sep 17 00:00:00 2001 From: seth Date: Tue, 30 May 2023 01:43:34 -0400 Subject: ci: separate workflows more + add more tests --- .github/workflows/format.yaml | 47 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 .github/workflows/format.yaml (limited to '.github/workflows/format.yaml') diff --git a/.github/workflows/format.yaml b/.github/workflows/format.yaml new file mode 100644 index 0000000..b0eaddd --- /dev/null +++ b/.github/workflows/format.yaml @@ -0,0 +1,47 @@ +name: format project + +on: + workflow_call: + workflow_dispatch: + +permissions: + contents: write + +jobs: + cargo-fmt: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: stable + override: true + components: clippy + + - name: run cargo fmt + uses: actions-rs/cargo@v1 + with: + command: fmt + args: --all + + - uses: EndBug/add-and-commit@v9 + with: + default_author: github_actions + message: "chore: fmt rust files" + + nix-fmt: + runs-on: ubuntu-latest + needs: cargo-fmt + steps: + - uses: actions/checkout@v3 + + - uses: cachix/install-nix-action@v21 + + - run: nix fmt + + - uses: EndBug/add-and-commit@v9 + with: + default_author: github_actions + message: "chore: fmt nix files" -- cgit v1.2.3