lint-and-validate

MANDATORY: Run appropriate validation tools after EVERY code change. Do not finish a task until the code is error-free.

31,392 stars
Complexity: easy

About this skill

The `lint-and-validate` skill empowers an AI agent to enforce stringent code quality standards by automatically executing a comprehensive suite of validation tools. This skill is explicitly marked as "MANDATORY" and requires the agent to ensure all generated or modified code is completely error-free before considering a task finished. It provides specific procedures for both Node.js/TypeScript (ESLint, TypeScript compiler, npm audit) and Python (Ruff, Bandit, MyPy) ecosystems. By integrating this skill, AI agents can maintain high development standards, prevent common errors, identify type mismatches, and detect security vulnerabilities early in the development cycle, acting as a crucial "Quality Loop" step to ensure robust and reliable code.

Best use case

An AI agent is tasked with implementing a new feature, fixing a bug, or refactoring existing code. Before submitting or committing the changes, the agent uses this skill to automatically check for linting errors, type inconsistencies, and security issues across the modified codebase.

MANDATORY: Run appropriate validation tools after EVERY code change. Do not finish a task until the code is error-free.

Confirmation that the code passes all linting, type checking, and security audits. A detailed report of any identified errors or warnings, along with suggested fixes, prompting the agent to iterate and resolve them. Clean, well-structured, type-safe, and secure code that adheres to defined project standards, ready for deployment or further integration.

Practical example

Example input

I have finished implementing the user authentication module in Python and its corresponding API endpoints in TypeScript. Please validate all new and modified code.

Example output

Agent: Running linting and validation for Node.js/TypeScript code...

1. Lint/Fix:
`npx eslint "src/api/auth.ts" --fix`
> Output: No linting issues found.

2. Types:
`npx tsc --noEmit`
> Output: No TypeScript compilation errors.

3. Security:
`npm audit --audit-level=high`
> Output: No high-severity vulnerabilities found in dependencies.

Agent: Running linting and validation for Python code...

1. Linter (Ruff):
`ruff check "src/auth_module.py" --fix`
> Output: No issues found.

2. Security (Bandit):
`bandit -r "src/auth_module.py" -ll`
> Output: No security issues identified with high or medium confidence.

3. Types (MyPy):
`mypy "src/auth_module.py"`
> Output: Success: no issues found in 1 source file.

All validation checks passed across both ecosystems. The code changes for the user authentication module are error-free and adhere to quality standards.

When to use this skill

  • After any code generation, modification, or refactoring task performed by the AI agent.
  • When the agent needs to ensure the highest code quality and adherence to project standards.
  • Before concluding any coding task to guarantee error-free and secure output.
  • In a continuous integration (CI) or local development environment managed by an AI agent where code quality is paramount.

When not to use this skill

  • When the AI agent's task does not involve code changes (e.g., generating documentation, answering questions unrelated to code development).
  • In scenarios where the agent lacks the necessary permissions or environment to execute local development tools and command-line interfaces.
  • If a project intentionally bypasses certain validation steps, though the skill itself marks this as 'MANDATORY' for robust development.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/lint-and-validate/SKILL.md --create-dirs "https://raw.githubusercontent.com/sickn33/antigravity-awesome-skills/main/plugins/antigravity-awesome-skills-claude/skills/lint-and-validate/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/lint-and-validate/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How lint-and-validate Compares

Feature / Agentlint-and-validateStandard Approach
Platform SupportClaudeLimited / Varies
Context Awareness High Baseline
Installation ComplexityeasyN/A

Frequently Asked Questions

What does this skill do?

MANDATORY: Run appropriate validation tools after EVERY code change. Do not finish a task until the code is error-free.

Which AI agents support this skill?

This skill is designed for Claude.

How difficult is it to install?

The installation complexity is rated as easy. You can find the installation instructions above.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

# Lint and Validate Skill

> **MANDATORY:** Run appropriate validation tools after EVERY code change. Do not finish a task until the code is error-free.

### Procedures by Ecosystem

#### Node.js / TypeScript
1. **Lint/Fix:** `npm run lint` or `npx eslint "path" --fix`
2. **Types:** `npx tsc --noEmit`
3. **Security:** `npm audit --audit-level=high`

#### Python
1. **Linter (Ruff):** `ruff check "path" --fix` (Fast & Modern)
2. **Security (Bandit):** `bandit -r "path" -ll`
3. **Types (MyPy):** `mypy "path"`

## The Quality Loop
1. **Write/Edit Code**
2. **Run Audit:** `npm run lint && npx tsc --noEmit`
3. **Analyze Report:** Check the "FINAL AUDIT REPORT" section.
4. **Fix & Repeat:** Submitting code with "FINAL AUDIT" failures is NOT allowed.

## Error Handling
- If `lint` fails: Fix the style or syntax issues immediately.
- If `tsc` fails: Correct type mismatches before proceeding.
- If no tool is configured: Check the project root for `.eslintrc`, `tsconfig.json`, `pyproject.toml` and suggest creating one.

---
**Strict Rule:** No code should be committed or reported as "done" without passing these checks.

---

## Scripts

| Script | Purpose | Command |
|--------|---------|---------|
| `scripts/lint_runner.py` | Unified lint check | `python scripts/lint_runner.py <project_path>` |
| `scripts/type_coverage.py` | Type coverage analysis | `python scripts/type_coverage.py <project_path>` |

## When to Use
This skill is applicable to execute the workflow or actions described in the overview.

Related Skills

cc-skill-coding-standards

31392
from sickn33/antigravity-awesome-skills

Universal coding standards, best practices, and patterns for TypeScript, JavaScript, React, and Node.js development.

Code Quality & StandardsClaude

deployment-validation-config-validate

31392
from sickn33/antigravity-awesome-skills

You are a configuration management expert specializing in validating, testing, and ensuring the correctness of application configurations. Create comprehensive validation schemas, implement configurat

DevOps ToolsClaude

nft-standards

31392
from sickn33/antigravity-awesome-skills

Master ERC-721 and ERC-1155 NFT standards, metadata best practices, and advanced NFT features.

Web3 & BlockchainClaude

nextjs-app-router-patterns

31392
from sickn33/antigravity-awesome-skills

Comprehensive patterns for Next.js 14+ App Router architecture, Server Components, and modern full-stack React development.

Web FrameworksClaude

new-rails-project

31392
from sickn33/antigravity-awesome-skills

Create a new Rails project

Code GenerationClaude

networkx

31392
from sickn33/antigravity-awesome-skills

NetworkX is a Python package for creating, manipulating, and analyzing complex networks and graphs.

Network AnalysisClaude

network-engineer

31392
from sickn33/antigravity-awesome-skills

Expert network engineer specializing in modern cloud networking, security architectures, and performance optimization.

Network EngineeringClaude

nestjs-expert

31392
from sickn33/antigravity-awesome-skills

You are an expert in Nest.js with deep knowledge of enterprise-grade Node.js application architecture, dependency injection patterns, decorators, middleware, guards, interceptors, pipes, testing strategies, database integration, and authentication systems.

Frameworks & LibrariesClaude

nerdzao-elite

31392
from sickn33/antigravity-awesome-skills

Senior Elite Software Engineer (15+) and Senior Product Designer. Full workflow with planning, architecture, TDD, clean code, and pixel-perfect UX validation.

Software DevelopmentClaude

nerdzao-elite-gemini-high

31392
from sickn33/antigravity-awesome-skills

Modo Elite Coder + UX Pixel-Perfect otimizado especificamente para Gemini 3.1 Pro High. Workflow completo com foco em qualidade máxima e eficiência de tokens.

Software DevelopmentClaudeGemini

native-data-fetching

31392
from sickn33/antigravity-awesome-skills

Use when implementing or debugging ANY network request, API call, or data fetching. Covers fetch API, React Query, SWR, error handling, caching, offline support, and Expo Router data loaders (useLoaderData).

API IntegrationClaude

n8n-workflow-patterns

31392
from sickn33/antigravity-awesome-skills

Proven architectural patterns for building n8n workflows.

Workflow AutomationClaude