From dbe09b9e7adee145444d4d230ab4fad9ee460612 Mon Sep 17 00:00:00 2001
From: Volkor <me@volkor.me>
Date: Wed, 22 Mar 2023 16:30:55 +1100
Subject: [PATCH] merge jobs

---
 .gitea/workflows/test.yaml | 39 +++++++-------------------------------
 1 file changed, 7 insertions(+), 32 deletions(-)

diff --git a/.gitea/workflows/test.yaml b/.gitea/workflows/test.yaml
index 1cc7dd3..2762f93 100644
--- a/.gitea/workflows/test.yaml
+++ b/.gitea/workflows/test.yaml
@@ -1,42 +1,17 @@
-# name: Format, check and test
+# I've merged all these into a single job since it's /way/ faster. caching should work for other jobs like building
 name: format, check and test
 on: [push, pull_request]
 
 jobs:
-  cache:
-    name: cargo-cache
+  fmt-check-test:
+    name: format check and test
     runs-on: ubuntu-latest
     steps:
       - uses: https://github.com/actions/checkout@v3
-      - uses: https://github.com/dtolnay/rust-toolchain@stable
-      - uses: https://github.com/Swatinem/rust-cache@v2
-
-  format:
-    name: cargo fmt
-    runs-on: ubuntu-latest
-    steps:
-      - uses: https://github.com/actions/checkout@v3
-      - uses: https://github.com/dtolnay/rust-toolchain@stable
-      - uses: https://github.com/Swatinem/rust-cache@v2      
+      - uses: https://github.com/dtolnay/rust-toolchain@stable   
         with:
-          components: rustfmt
+          components: rustfmt, clippy
       - run: cargo fmt -- --all-features
-
-  clippy:
-    name: cargo clippy
-    runs-on: ubuntu-latest
-    steps:
-      - uses: https://github.com/actions/checkout@v3
-      - uses: https://github.com/dtolnay/rust-toolchain@stable
-        with:
-          components: clippy
-      - uses: https://github.com/Swatinem/rust-cache@v2
       - run: cargo clippy --all-features
-  test:
-    name: cargo test
-    runs-on: ubuntu-latest
-    steps:
-      - uses: https://github.com/actions/checkout@v3
-      - uses: https://github.com/dtolnay/rust-toolchain@stable
-      - uses: https://github.com/Swatinem/rust-cache@v2
-      - run: cargo test --all-features
\ No newline at end of file
+      - run: cargo test --all-features
+      - uses: https://github.com/Swatinem/rust-cache@v2   
\ No newline at end of file
-- 
GitLab