fix(release):完善当前分发证明与质量门禁
bat-rust / Build and test Rust (push) Canceled after 0s
bat-rust / Build and test Go API (push) Canceled after 0s

This commit is contained in:
2026-09-14 06:39:47 +08:00
parent c17904ee1c
commit 13b0bd5b45
39 changed files with 1590 additions and 228 deletions
+13 -8
View File
@@ -118,14 +118,19 @@ lint-rust: ## Rust Clippy 检查
@echo "$(BLUE)Running Clippy...$(NC)"
cargo clippy --workspace --all-targets -- -D warnings
lint-go: ## Go Linter 检查
lint-go: ## Go Linter 检查required
@echo "$(BLUE)Running golangci-lint...$(NC)"
@command -v golangci-lint >/dev/null 2>&1 || { echo "$(YELLOW)OPTIONAL gate skipped: golangci-lint is not installed$(NC)"; exit 0; }
@if [ -n "$$(go list ./... 2>/dev/null)" ]; then \
XDG_CACHE_HOME="$${XDG_CACHE_HOME:-/tmp/bat-xdg-cache}" golangci-lint run ./...; \
else \
echo "$(YELLOW)No Go packages yet, skipping...$(NC)"; \
fi
@. scripts/ci-versions.sh; \
command -v golangci-lint >/dev/null 2>&1 || { \
echo "$(YELLOW)required gate failed: golangci-lint $${GOLANGCI_LINT_VERSION} is not installed$(NC)"; \
exit 1; \
}; \
actual="$$(golangci_lint_actual_version)"; \
test "$${actual}" = "$${GOLANGCI_LINT_VERSION}" || { \
echo "$(YELLOW)required gate failed: golangci-lint version required=$${GOLANGCI_LINT_VERSION} actual=$${actual:-unknown}$(NC)"; \
exit 1; \
}; \
XDG_CACHE_HOME="$${XDG_CACHE_HOME:-/tmp/bat-xdg-cache}" golangci-lint run ./...
# ============================================================================
# 清理
@@ -191,7 +196,7 @@ docs: ## 生成文档
# CI/CD
# ============================================================================
ci-check: ## 运行只读 required CI 门禁(可选 lint 会明确标记
ci-check: ## 运行只读 required CI 门禁(含固定版本 Go lint
@bash scripts/ci-check.sh
ci: ci-check ## 运行只读 CI 检查(兼容旧命令名)