mirror of
https://github.com/mukul975/Anthropic-Cybersecurity-Skills.git
synced 2026-06-10 13:14:55 +03:00
efc9598525
Three issues fixed: 1. Description list check — added elif isinstance(desc, list) branch that emits 'Description must be a string value, not a list'. Previously the block was silently skipped when YAML returned a list, causing the skill to pass without validating the description field. 2. tools/README.md synced — updated description constraint from '20-500 characters' to 'at least 50 characters (no upper limit)' to match the current code (DESCRIPTION_MIN_CHARS=50, no max enforced). 3. --all with wrong CWD now exits 1 — if glob returns no skill dirs, the script prints an error and exits with code 1 instead of reporting 'Total: 0 Passed: 0 Failed: 0' and exiting 0, which would cause CI to silently pass while validating nothing. All 754 skills continue to pass (0 regressions).
31 lines
761 B
Markdown
31 lines
761 B
Markdown
# Skill Validation Tools
|
||
|
||
## validate-skill.py
|
||
|
||
Validate SKILL.md metadata before submitting a PR.
|
||
|
||
### Usage
|
||
|
||
```bash
|
||
# Validate a single skill
|
||
python tools/validate-skill.py skills/my-new-skill/
|
||
|
||
# Validate all skills
|
||
python tools/validate-skill.py --all
|
||
```
|
||
|
||
### What it checks
|
||
|
||
- SKILL.md exists in the skill directory
|
||
- Valid YAML frontmatter (between `---` markers)
|
||
- Required fields present: `name`, `description`, `domain`, `subdomain`, `tags`
|
||
- Name is kebab-case, 1–64 characters
|
||
- Description is at least 50 characters (no upper limit; multi-line folded scalars are valid)
|
||
- Domain is `cybersecurity`
|
||
- Subdomain is from the allowed list
|
||
- Tags is a list with at least 2 items
|
||
|
||
### Requirements
|
||
|
||
Python 3.8+ (stdlib only, no external dependencies)
|