// MANDATORY for discovering test, lint, and build commands. Prioritizes CI configurations as source of truth, with intelligent fallback to project manifests. Always consult this skill before running quality checks, build commands, or creating PRs.
| name | ci-discovery |
| description | MANDATORY for discovering test, lint, and build commands. Prioritizes CI configurations as source of truth, with intelligent fallback to project manifests. Always consult this skill before running quality checks, build commands, or creating PRs. |
Search for CI configurations. These usually live in the root of a repository so if not found there, check parent directories as you may be in a monorepo.
.github/workflows/*.{yml,yaml}.gitlab-ci.yml.circleci/config.yml.travis.yml.buildkite/pipeline.ymlJenkinsfileSTEP 2: Extract EXACT Commands from CI
Look for these command types in CI jobs/steps:
Test commands:
npm test, mix test, cargo test, pytest, go test, make testLint commands (COMPREHENSIVE - find ALL):
eslint, mix format --check-formatted, cargo clippy, ruff checkprettier --check, black --check, cargo fmt -- --checkrubocop, pylint, flake8, credo, golangci-lintnpm audit, cargo audit, bundle auditnpm run lint:custom, ./scripts/lint.shmix ecto.validate, schema checks--warnings-as-errors, -D warnings, --strictBuild commands:
npm run build, mix compile, cargo build, make build, tscTypecheck commands:
tsc --noEmit, mypy, dialyzer, flow checkDatabase Linting/Checks:
sqlfluff lint, pg_format --check, dbt test, mix excellent_migrations.*Extraction rules:
npm ci before npm test, include bothnpm test vs npm run test matters, match CI exactlyif conditions, include commands only if they would run in normal flowExample - Look for jobs.<job_id>.steps[].run:
jobs:
test:
steps:
- run: npm ci
- run: npm test
- run: ./scripts/report-coverage.sh
- run: npm run build
- run: ./scripts/custom-check.sh
- run: echo "Done"
Extract: npm ci && npm test && npm run build && ./scripts/custom-check.sh
If you see a build step with --warnings-as-errors, then ensure that is also run in the correct order as that acts as a linting circuit breaker.
If CI found, STOP HERE. Use ONLY CI commands. Do NOT check project files.
STEP 3: Fallback to Project Files (ONLY if NO CI)
ONLY use this if NO CI files were found!
pnpm-lock.yaml > yarn.lock > package-lock.json) or manifest (mix.exs, Cargo.toml, etc.):test, lint*, format*, style*, typecheck, buildIf nothing found:
"I know the project uses npm test" WRONG: Check CI to be sure
"CI files are too complicated to parse" WRONG: Extract EXACT commands anyway
"Project files are good enough" WRONG: CI is ALWAYS source of truth if it exists
"I found package.json so I don't need to check CI" WRONG: ALWAYS check CI FIRST
"I'll simplify the command" WRONG: Use EXACT command from CI
NO EXCEPTIONS
**MANDATORY CHECKLIST:**โ Checked for CI configuration (.github/workflows/.yml, ../.github/workflows/.yml, .gitlab-ci.yml, etc...) โ If CI found, extracted EXACT commands โ If CI found, did NOT check project files โ Preserved command order from CI โ Included setup/install commands โ Only checked project files if NO CI exists โ Did NOT modify, guess, or invent commands
IF ANY UNCHECKED THEN EVERYTHING FAILS AT PR TIME