ci-preflight
Skill1 starsChanged 5 months agoMITView on GitHub
Pre-push CI validation — reads .github/workflows/, runs the same checks locally (type-check, lint, test, build) before code is committed, preventing CI failures on GitHub. Use when completing a feature or before marking work as done.
- Installs packages
3 other projects use a version of this.
Adopted by
Most recently taken up by
- n1m21n/Infinitetheir own version, first seen Nov 2, 2026
- The-Artificer-of-Ciphers-LLC/skills-from-the-artificertheir own version, first seen Oct 14, 2026
- matteing/opaltheir own version, first seen Feb 16, 2026
Other versions3 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 3
- n1m21n/Infinite★ 318same name
- matteing/opal★ 59same name
- The-Artificer-of-Ciphers-LLC/skills-from-the-artificer★ 6same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository15 other files it gives its agents.
- code-reviewSkill
- debugSkill
- docx-processingSkill
- github-publishSkill
- implementSkill
- pdf-processingSkill
- permission-modesSkill
- planSkill
- pptx-processingSkill
- refactorSkill
- security-testingSkill
- specSkill
- testSkill
- web-developmentSkill
- xlsx-processingSkill
The file
Files
CI Preflight — 推前预检 Skill(参考文档)
说明
CI 预检行为已在 APPEND_SYSTEM.md 中作为永久系统指令启用。 本 skill 作为参考文档,包含详细的命令和逻辑说明。
完整执行流程
Step 1: 检查 CI 配置
ls .github/workflows/*.yml 2>/dev/null || echo "NO_CI"如果有 CI 配置 → 读取全部 workflow 文件,提取步骤 如果无 CI 配置 → 根据检测到的项目类型走默认检查
Step 2: 按项目类型执行检查
Node.js 项目(每项设 60s 超时)
timeout 60 npm ci --ignore-scripts 2>/dev/null # 依赖一致性
timeout 60 npx tsc --noEmit 2>/dev/null # 类型检查
timeout 60 npx eslint src/ --max-warnings 0 2>/dev/null # 代码规范
timeout 60 node --test tests/*.test.ts 2>/dev/null # 单元测试
timeout 60 npm run build 2>/dev/null # 构建Python 项目
pip install -r requirements.txt -q 2>/dev/null # 依赖
mypy src/ 2>/dev/null # 类型
ruff check src/ 2>/dev/null # 规范
pytest tests/ -q 2>/dev/null # 测试Rust 项目
cargo check 2>/dev/null
cargo clippy 2>/dev/null
cargo test 2>/dev/nullGo 项目
go mod tidy 2>/dev/null
go vet ./... 2>/dev/null
go test ./... 2>/dev/null
go build ./... 2>/dev/null无法确定项目类型 → 至少检查:
- README/文档是否完整
- 是否有明文密钥/硬编码凭据
- 编码风格是否与项目已有代码一致
- 新文件是否有对应的测试
Step 3: 自动修复(带上限)
每项失败时:
- 读取完整错误输出(不是只看最后几行)
- 定位根因 — 类型错误?格式问题?缺少依赖?
- 做最小修复 — 不要重构周围代码,不要改 CI 配置文件
- 重新运行该项(最多 3 次)
- 3 次仍失败 → 记录到报告中,跳过,继续下一项
- 修完当前项后必须从 Step 2 开头重跑整个检查链条
- 连续 5 轮重跑后仍有失败 → 停止并向用户报告
Step 4: 输出预检报告
✅ CI Preflight 完成
├── npm ci: 通过
├── tsc --noEmit: 通过 (1 个新错误→已修复)
├── eslint: 通过 (0 warnings)
├── tests: 通过 (12/12)
└── build: 通过有 3 次修复仍失败的项 → 输出失败详情 → 不要标记完成
特殊情况
| 场景 | 处理方式 |
| 项目无 CI 配置 | 走默认检查(按检测到的项目类型) |
| CI 有 Docker/deploy 等无法本地跑的步骤 | 跳过并在报告中注明 |
| 存量项目有 100+ 存量类型错误 | 只修改动的文件引入的新错误 |
| 用户明确说"不用检查" | 跳过,不跑预检 |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

