add-dart-lint-validation-rule

Create and register custom validation rules for dart_skills_lint.

2.8k|166|Updated Feb 25, 2026
One-click install
npx skills add https://github.com/flutter/agent-plugins --skill add-dart-lint-validation-rule
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: add-dart-lint-validation-rule
Source: https://github.com/flutter/agent-plugins/tree/main/tool/dart_skills_lint/.agents/skills/add-dart-lint-validation-rule
Command: npx skills add https://github.com/flutter/agent-plugins --skill add-dart-lint-validation-rule

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill streamlines the process of extending the dart_skills_lint package by providing a structured workflow for creating, registering, and testing new validation rules for skill metadata.

Core Features & Use Cases

  • Rule Scaffolding: Provides a template for creating new validation classes that extend SkillRule.
  • Registry Integration: Guides the registration of new rules into the central registry for CLI exposure.
  • Testing Framework: Offers standardized approaches for both in-memory unit testing and file-system integration testing.
  • Use Case: Use this when you need to enforce a new constraint on skill frontmatter, such as requiring a specific version field or ensuring the presence of mandatory supplementary files.

Quick Start

Use the add-dart-lint-validation-rule skill to generate a new rule class and register it in the rule registry.

Frequently Asked Questions about add-dart-lint-validation-rule

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add custom validation rules to dart_skills_lint?

Custom validation rules in dart_skills_lint are created by extending the SkillRule class. You must register new rules in the central registry to expose them via the CLI for automated quality checks.

What is the best way to enforce constraints on skill metadata in Dart?

Enforcing constraints on skill metadata is done by implementing custom validation classes. This skill provides scaffolding to define rules requiring specific frontmatter fields or mandatory supplementary files.

How do I test custom linting rules for skill file structures?

Testing custom linting rules involves using standardized approaches for in-memory unit testing and file-system integration testing. This ensures validation logic correctly evaluates skill metadata and file structures.

When do I need custom validation rules for skill metadata?

Custom validation rules are needed when you must enforce new constraints on skill frontmatter, such as requiring a specific version field or ensuring mandatory supplementary files are present alongside the skill.

Does dart_skills_lint support automated registry integration for new rules?

Yes, dart_skills_lint supports registry integration. It guides the registration of newly scaffolded validation rules into the central registry, making them immediately available for CLI exposure and automated testing.