ci: do not create a pipeline for docs-only commits
Same trap as in ThreadNet-Web: a commit touching only docs/ produced a pipeline with zero jobs, which GitLab marks as failed - pipeline 187 on 2026-08-06. build_embedded is skipped by its changes rule and publish_npm depends on it, so nothing is left. The path list is now a YAML anchor shared with build_embedded instead of a second copy. CI_PIPELINE_SOURCE == web stays allowed so publish_npm remains reachable after a docs-only commit. Refs axion1337.chat/threadnet-call#1
This commit is contained in:
+37
-11
@@ -3,6 +3,38 @@
|
|||||||
# Trigger-Schema wie ThreadNet-Web: Pushes pruefen nur bei relevanten Pfaden,
|
# Trigger-Schema wie ThreadNet-Web: Pushes pruefen nur bei relevanten Pfaden,
|
||||||
# Veroeffentlichen ist ein bewusster manueller Akt.
|
# Veroeffentlichen ist ein bewusster manueller Akt.
|
||||||
|
|
||||||
|
# --- Wann ueberhaupt eine Pipeline entsteht ------------------------------------
|
||||||
|
# Gleiche Falle wie in ThreadNet-Web: Ein Commit, der nur docs/ anfasst, erzeugt
|
||||||
|
# eine Pipeline mit NULL Jobs - und die zaehlt als "failed". Real passiert am
|
||||||
|
# 2026-08-06 (Pipeline 187). Ursache ist die needs-Kette: build_embedded laeuft
|
||||||
|
# wegen changes: nicht, publish_npm haengt per needs daran, und damit bleibt gar
|
||||||
|
# nichts uebrig.
|
||||||
|
#
|
||||||
|
# ⚠️ Rot, das nichts bedeutet, gewoehnt einem das Hinsehen ab - und in diesem
|
||||||
|
# Verbund IST die rote Pipeline die Alarmanlage (siehe gitops/CLAUDE.md zur
|
||||||
|
# TURN-Rotation).
|
||||||
|
#
|
||||||
|
# CI_PIPELINE_SOURCE == "web" bleibt erlaubt, damit publish_npm auch nach einem
|
||||||
|
# reinen Doku-Commit ueber "Run pipeline" erreichbar ist.
|
||||||
|
.pfade_mit_pipeline: &pfade_mit_pipeline
|
||||||
|
- src/**/*
|
||||||
|
- embedded/**/*
|
||||||
|
- public/**/*
|
||||||
|
- package.json
|
||||||
|
- pnpm-lock.yaml
|
||||||
|
- vite*.config.*
|
||||||
|
- .env.production
|
||||||
|
- .gitlab-ci.yml
|
||||||
|
|
||||||
|
workflow:
|
||||||
|
rules:
|
||||||
|
- if: $CI_COMMIT_TAG =~ /^v/
|
||||||
|
- if: $CI_PIPELINE_SOURCE == "schedule"
|
||||||
|
- if: $CI_PIPELINE_SOURCE == "web"
|
||||||
|
- if: $CI_COMMIT_BRANCH
|
||||||
|
changes: *pfade_mit_pipeline
|
||||||
|
- when: never
|
||||||
|
|
||||||
stages:
|
stages:
|
||||||
- build
|
- build
|
||||||
- publish
|
- publish
|
||||||
@@ -13,17 +45,11 @@ build_embedded:
|
|||||||
rules:
|
rules:
|
||||||
- if: $CI_COMMIT_TAG =~ /^v/
|
- if: $CI_COMMIT_TAG =~ /^v/
|
||||||
- if: $CI_COMMIT_BRANCH
|
- if: $CI_COMMIT_BRANCH
|
||||||
changes:
|
# derselbe Anker wie im workflow-Block oben - zwei Listen wuerden driften.
|
||||||
- src/**/*
|
# .env.production steht dort mit drin: sie setzt VITE_PRODUCT_NAME und landet
|
||||||
- embedded/**/*
|
# damit im Bundle - ohne den Eintrag aendert man den Produktnamen und die CI
|
||||||
- public/**/*
|
# baut gar nicht erst.
|
||||||
- package.json
|
changes: *pfade_mit_pipeline
|
||||||
- pnpm-lock.yaml
|
|
||||||
- vite*.config.*
|
|
||||||
# .env.production setzt VITE_PRODUCT_NAME und landet damit im Bundle - ohne
|
|
||||||
# diesen Eintrag aendert man den Produktnamen und die CI baut gar nicht erst.
|
|
||||||
- .env.production
|
|
||||||
- .gitlab-ci.yml
|
|
||||||
before_script:
|
before_script:
|
||||||
- corepack enable
|
- corepack enable
|
||||||
script:
|
script:
|
||||||
|
|||||||
Reference in New Issue
Block a user