From 3133671c023d53fae07ba20146dc38fe14e7f536 Mon Sep 17 00:00:00 2001 From: datadunia Date: Wed, 10 Jun 2026 03:45:01 +0700 Subject: [PATCH] ci: test only for tags with 'test' in name --- .gitea/workflows/ci.yml | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index b02f420..80536d3 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -10,9 +10,10 @@ on: jobs: # ────────────────────────────────────────────── - # TEST — all 3 components in parallel (always) + # TEST — only for tags with "test" in name # ────────────────────────────────────────────── server-core-test: + if: contains(gitea.ref_name, 'test') runs-on: ubuntu-latest defaults: run: @@ -29,6 +30,7 @@ jobs: run: go test ./... -tags dev -cover device-agent-test: + if: contains(gitea.ref_name, 'test') runs-on: ubuntu-latest defaults: run: @@ -45,6 +47,7 @@ jobs: run: go test ./... -cover dashboard-test: + if: contains(gitea.ref_name, 'test') runs-on: ubuntu-latest defaults: run: @@ -63,32 +66,28 @@ jobs: run: npm run build # ────────────────────────────────────────────── - # BUILD — only on tag push, parallel per component + # BUILD — all tags, parallel per component # ────────────────────────────────────────────── build-server-core: - if: startsWith(gitea.ref, 'refs/tags/') - needs: [server-core-test] + runs-on: ubuntu-latest uses: ./.gitea/workflows/build_server_core.yaml build-device-agent: - if: startsWith(gitea.ref, 'refs/tags/') - needs: [device-agent-test] + runs-on: ubuntu-latest uses: ./.gitea/workflows/build_device_agent.yaml build-dashboard: - if: startsWith(gitea.ref, 'refs/tags/') - needs: [dashboard-test] + runs-on: ubuntu-latest uses: ./.gitea/workflows/build_dashboard.yaml build-docs: - if: startsWith(gitea.ref, 'refs/tags/') + runs-on: ubuntu-latest uses: ./.gitea/workflows/docs_call.yaml # ────────────────────────────────────────────── # RELEASE — after all builds complete # ────────────────────────────────────────────── release: - if: startsWith(gitea.ref, 'refs/tags/') needs: [build-server-core, build-device-agent, build-dashboard, build-docs] uses: ./.gitea/workflows/release_call.yaml with: