feat: 1、流水线总开关配置 2、删除p0p1p2级别阻断
All checks were successful
Redis序列化结构检查 / redis-schema-check (push) Has been skipped

This commit is contained in:
2026-07-14 10:58:05 +08:00
parent 7a8ca7ce0b
commit 114b053733
10 changed files with 74 additions and 68 deletions

View File

@@ -30,9 +30,19 @@ jobs:
echo "错误: 缺少 .gitea/config/redis-schema-check-config.yaml"
exit 1
fi
# 顶层总开关 enabled: false 时跳过后续步骤(与 notify.enabled 区分,仅匹配行首)
if grep -Eq '^enabled:[[:space:]]*false([[:space:]]|#|$)' .gitea/config/redis-schema-check-config.yaml; then
echo "总开关 enabled=false跳过 Redis 结构检查"
touch /tmp/redis-schema-check.skip
fi
- name: 从 Nexus 私库下载 redis-schema-checker
run: |
if [ -f /tmp/redis-schema-check.skip ]; then
echo "总开关已关闭,跳过下载"
exit 0
fi
GROUP_PATH="com/codechecker/redis-schema-checker"
JAR_NAME="redis-schema-checker-${REDIS_SCHEMA_CHECKER_VERSION}.jar"
JAR_URL="${REDIS_SCHEMA_CHECKER_REPO_URL}/${GROUP_PATH}/${REDIS_SCHEMA_CHECKER_VERSION}/${JAR_NAME}"
@@ -57,10 +67,19 @@ jobs:
- name: 验证 JDK
run: |
if [ -f /tmp/redis-schema-check.skip ]; then
echo "总开关已关闭,跳过"
exit 0
fi
echo "Java: $(java -version 2>&1 | head -1)"
- name: 执行 Redis 序列化结构检测
run: |
if [ -f /tmp/redis-schema-check.skip ]; then
echo "总开关已关闭,跳过检测"
exit 0
fi
OLD_SHA=$(git rev-parse HEAD~1 2>/dev/null || echo "")
if [ -z "$OLD_SHA" ]; then
echo "首次提交,跳过检测"