ワンクリックで
lint-and-validate
Linting and validation principles for code quality enforcement.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Linting and validation principles for code quality enforcement.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Senior agent organizer with expertise in assembling and coordinating multi-agent teams. Your focus spans task analysis, agent capability mapping, workflow design, and team optimization.
AI agent design principles. Agent loops, tool calling, memory architectures, multi-agent coordination, human-in-the-loop gates, and guardrails. Use when building AI agents, autonomous workflows, or any system where an LLM plans and executes multi-step tasks.
API design principles and decision-making. REST vs GraphQL vs tRPC selection, response formats, versioning, pagination.
Main application building orchestrator. Creates full-stack applications from natural language requests. Determines project type, selects tech stack, coordinates agents.
Architectural decision-making framework. Requirements analysis, trade-off evaluation, ADR documentation. Use when making architecture decisions or analyzing system design.
Bash/Linux terminal patterns. Critical commands, piping, error handling, scripting. Use when working on macOS or Linux systems.
| name | lint-and-validate |
| description | Linting and validation principles for code quality enforcement. |
| allowed-tools | Read, Write, Edit, Glob, Grep |
| version | 1.0.0 |
| last-updated | "2026-03-12T00:00:00.000Z" |
| applies-to-model | gemini-2.5-pro, claude-3-7-sonnet |
A linter is an automated code reviewer that never gets tired, never gets distracted, and catches the same class of problems every single time.
Linting catches problems that code review misses:
await on async functions (silently returns a Promise instead of the value)== instead of === in JS)Run linting in CI. Every PR that merges should pass lint. A lint check that doesn't block the build is decoration.
# Install
npm install -D eslint @typescript-eslint/eslint-plugin @typescript-eslint/parser prettier
# Run
npx eslint . --ext .ts,.tsx
npx prettier --check .
# Fix auto-fixable issues
npx eslint . --ext .ts,.tsx --fix
npx prettier --write .
Recommended rules to enforce:
// .eslintrc.json
{
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:@typescript-eslint/recommended-requiring-type-checking"
],
"rules": {
"@typescript-eslint/no-explicit-any": "error",
"@typescript-eslint/no-floating-promises": "error",
"@typescript-eslint/await-thenable": "error",
"no-console": ["warn", { "allow": ["warn", "error"] }],
"eqeqeq": ["error", "always"]
}
}
Key rules explained:
| Rule | Why It Matters |
|---|---|
no-floating-promises | Missing await on async call = silent bug |
no-explicit-any | any disables TypeScript's only protection |
eqeqeq | == has coercion surprises; === is always explicit |
await-thenable | Prevents await-ing non-async functions (always a mistake) |
Ruff replaces flake8, black, isort, and pyupgrade in one fast tool:
# Install
pip install ruff
# Check
ruff check .
# Fix auto-fixable
ruff check . --fix
# Format (replaces black)
ruff format .
# Pre-commit config
# .pre-commit-config.yaml
- repo: https://github.com/astral-sh/ruff-pre-commit
hooks:
- id: ruff
args: [--fix]
- id: ruff-format
# pyproject.toml
[tool.ruff]
line-length = 100
target-version = "py311"
[tool.ruff.lint]
select = ["E", "F", "I", "N", "UP", "B", "SIM", "ANN"]
# E: pycodestyle, F: pyflakes, I: isort, N: naming, UP: pyupgrade
# B: bugbear (common bugs), SIM: simplify, ANN: annotations
Linting and type checking catch different things. Run both.
TypeScript:
npx tsc --noEmit # type check without emitting files
Python:
mypy src/ --ignore-missing-imports
# or
pyright src/
Required compiler options (TypeScript):
{
"compilerOptions": {
"strict": true, // enables all strict checks
"noImplicitAny": true,
"noUncheckedIndexedAccess": true, // index access can be undefined
"exactOptionalPropertyTypes": true
}
}
Run linting automatically before every commit:
# .pre-commit-config.yaml
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
hooks:
- id: check-merge-conflict
- id: check-added-large-files
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: local
hooks:
- id: eslint
name: ESLint
language: node
entry: npx eslint --ext .ts,.tsx
types: [javascript, ts]
- id: tsc
name: TypeScript
language: node
entry: npx tsc --noEmit
pass_filenames: false
| Script | Purpose | Run With |
|---|---|---|
scripts/lint_runner.py | Runs project linting and reports findings | python scripts/lint_runner.py <project_path> |
scripts/type_coverage.py | Measures TypeScript type coverage | python scripts/type_coverage.py <project_path> |
When this skill produces or reviews code, structure your output as follows:
━━━ Lint And Validate Report ━━━━━━━━━━━━━━━━━━━━━━━━
Skill: Lint And Validate
Language: [detected language / framework]
Scope: [N files · N functions]
─────────────────────────────────────────────────
✅ Passed: [checks that passed, or "All clean"]
⚠️ Warnings: [non-blocking issues, or "None"]
❌ Blocked: [blocking issues requiring fix, or "None"]
─────────────────────────────────────────────────
VBC status: PENDING → VERIFIED
Evidence: [test output / lint pass / compile success]
VBC (Verification-Before-Completion) is mandatory. Do not mark status as VERIFIED until concrete terminal evidence is provided.
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
// VERIFY or check package.json / requirements.txt.Slash command: /review or /tribunal-full
Active reviewers: logic-reviewer · security-auditor
// VERIFY: [reason].Review these questions before confirming output:
✅ Did I rely ONLY on real, verified tools and methods?
✅ Is this solution appropriately scoped to the user's constraints?
✅ Did I handle potential failure modes and edge cases?
✅ Have I avoided generic boilerplate that doesn't add value?
CRITICAL: You must follow a strict "evidence-based closeout" state machine.