From 01539730c061c382d4caa8879c99588ab4aca408 Mon Sep 17 00:00:00 2001
From: oliverpool <git@olivier.pfad.fr>
Date: Fri, 9 Feb 2024 11:08:19 +0100
Subject: [PATCH 1/3] CI: merge checks-backend and lint-backend

---
 .forgejo/workflows/testing.yml | 25 ++++++-------------------
 1 file changed, 6 insertions(+), 19 deletions(-)

diff --git a/.forgejo/workflows/testing.yml b/.forgejo/workflows/testing.yml
index dd0b280dc4..4270a30bef 100644
--- a/.forgejo/workflows/testing.yml
+++ b/.forgejo/workflows/testing.yml
@@ -8,7 +8,7 @@ on:
       - 'v*/forgejo*'
 
 jobs:
-  lint-backend:
+  backend-checks:
     if: ${{ !startsWith(vars.ROLE, 'forgejo-') }}
     runs-on: docker
     container:
@@ -20,26 +20,13 @@ jobs:
           go-version: "1.21"
           check-latest: true
       - run: make deps-backend deps-tools
-      - run: make lint-backend
+      - run: make --always-make lint-backend checks-backend # ensure the "go-licenses" make target runs
         env:
           TAGS: bindata sqlite sqlite_unlock_notify
-  checks-backend:
-    if: ${{ !startsWith(vars.ROLE, 'forgejo-') }}
-    runs-on: docker
-    container:
-      image: 'docker.io/node:20-bookworm'
-    steps:
-      - uses: https://code.forgejo.org/actions/checkout@v3
-      - uses: https://code.forgejo.org/actions/setup-go@v4
-        with:
-          go-version: "1.21"
-          check-latest: true
-      - run: make deps-backend deps-tools
-      - run: make --always-make checks-backend # ensure the "go-licenses" make target runs
   test-unit:
     if: ${{ !startsWith(vars.ROLE, 'forgejo-') }}
     runs-on: docker
-    needs: [lint-backend, checks-backend]
+    needs: [backend-checks]
     container:
       image: 'docker.io/node:20-bookworm'
     services:
@@ -80,7 +67,7 @@ jobs:
   test-mysql:
     if: ${{ !startsWith(vars.ROLE, 'forgejo-') }}
     runs-on: docker
-    needs: [lint-backend, checks-backend]
+    needs: [backend-checks]
     container:
       image: 'docker.io/node:20-bookworm'
     services:
@@ -126,7 +113,7 @@ jobs:
   test-pgsql:
     if: ${{ !startsWith(vars.ROLE, 'forgejo-') }}
     runs-on: docker
-    needs: [lint-backend, checks-backend]
+    needs: [backend-checks]
     container:
       image: 'docker.io/node:20-bookworm'
     services:
@@ -174,7 +161,7 @@ jobs:
   test-sqlite:
     if: ${{ !startsWith(vars.ROLE, 'forgejo-') }}
     runs-on: docker
-    needs: [lint-backend, checks-backend]
+    needs: [backend-checks]
     container:
       image: 'docker.io/node:20-bookworm'
     steps:

From cab17d7a726091fc725148f88d34847712870a94 Mon Sep 17 00:00:00 2001
From: oliverpool <git@olivier.pfad.fr>
Date: Fri, 9 Feb 2024 11:20:15 +0100
Subject: [PATCH 2/3] DEBUG: -j

---
 .forgejo/workflows/testing.yml | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/.forgejo/workflows/testing.yml b/.forgejo/workflows/testing.yml
index 4270a30bef..dd69b2f24c 100644
--- a/.forgejo/workflows/testing.yml
+++ b/.forgejo/workflows/testing.yml
@@ -20,7 +20,8 @@ jobs:
           go-version: "1.21"
           check-latest: true
       - run: make deps-backend deps-tools
-      - run: make --always-make lint-backend checks-backend # ensure the "go-licenses" make target runs
+      - run: echo $(nproc)
+      - run: make --always-make -j$(nproc) lint-backend checks-backend # ensure the "go-licenses" make target runs
         env:
           TAGS: bindata sqlite sqlite_unlock_notify
   test-unit:

From ffc94d946369ac6190ab2e2883408e565fce8caa Mon Sep 17 00:00:00 2001
From: oliverpool <git@olivier.pfad.fr>
Date: Fri, 9 Feb 2024 11:27:58 +0100
Subject: [PATCH 3/3] remove debug print

---
 .forgejo/workflows/testing.yml | 1 -
 1 file changed, 1 deletion(-)

diff --git a/.forgejo/workflows/testing.yml b/.forgejo/workflows/testing.yml
index dd69b2f24c..a4b54c4da5 100644
--- a/.forgejo/workflows/testing.yml
+++ b/.forgejo/workflows/testing.yml
@@ -20,7 +20,6 @@ jobs:
           go-version: "1.21"
           check-latest: true
       - run: make deps-backend deps-tools
-      - run: echo $(nproc)
       - run: make --always-make -j$(nproc) lint-backend checks-backend # ensure the "go-licenses" make target runs
         env:
           TAGS: bindata sqlite sqlite_unlock_notify