mirror of
https://github.moeyy.xyz/https://github.com/GeWuYou/forgeboot
synced 2025-10-27 16:24:22 +08:00
ci: 修改标签和发布阶段的规则条件
- 将规则条件从匹配特定前缀改为包含 "ci" 字符串 -统一规则条件,使标签和发布阶段使用相同的规则 -改进规则的可读性和可维护性
This commit is contained in:
parent
1ce39f6f17
commit
bf1983ef62
@ -15,7 +15,7 @@ tag:
|
|||||||
stage: tag
|
stage: tag
|
||||||
image: alpine:latest
|
image: alpine:latest
|
||||||
rules:
|
rules:
|
||||||
- if: '$CI_COMMIT_BRANCH == "main" && $CI_COMMIT_MESSAGE !~ /^ci:|^chore:|^\[no-publish\]/'
|
- if: '$CI_COMMIT_BRANCH == "main" && $CI_COMMIT_MESSAGE !~ /ci/i'
|
||||||
script:
|
script:
|
||||||
- set -euo pipefail
|
- set -euo pipefail
|
||||||
- apk add --no-cache git
|
- apk add --no-cache git
|
||||||
@ -55,7 +55,7 @@ publish:
|
|||||||
stage: publish
|
stage: publish
|
||||||
needs: [ "tag" ]
|
needs: [ "tag" ]
|
||||||
rules:
|
rules:
|
||||||
- if: '$CI_COMMIT_BRANCH == "main" && $CI_COMMIT_MESSAGE !~ /^ci:|^chore:|^\[no-publish\]/'
|
- if: '$CI_COMMIT_BRANCH == "main" && $CI_COMMIT_MESSAGE !~ /ci/i'
|
||||||
cache:
|
cache:
|
||||||
key:
|
key:
|
||||||
files:
|
files:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user