| Crates.io | madskills-core |
| lib.rs | madskills-core |
| version | 0.1.1 |
| created_at | 2025-12-31 01:16:52.472915+00 |
| updated_at | 2025-12-31 01:16:52.472915+00 |
| description | Core library for madskills - skill discovery, parsing, and validation |
| homepage | https://madskill.ing |
| repository | https://github.com/madskilling/madskills |
| max_upload_size | |
| id | 2013709 |
| size | 169,974 |
CLI tool for validating and managing Agent Skills repositories.
brew install madskilling/brew/madskills
Download the latest release for your platform from the releases page.
cargo install madskills
Or build from source:
git clone https://github.com/madskilling/madskills.git
cd madskills
cargo install --path crates/madskills
madskills lint - Validate skillsValidates skills against the AgentSkills specification and runs markdown linting.
# Lint all skills in current directory
madskills lint
# Lint specific directory
madskills lint path/to/skills
# Strict mode (warnings become errors)
madskills lint --strict
# JSON output for CI
madskills lint --format json
# Only spec validation (skip markdown linting)
madskills lint --no-mdlint
# Only markdown linting (skip spec validation)
madskills lint --no-spec
Exit codes:
0: No issues found2: Errors found (or warnings in --strict mode)3: Internal failuremadskills list - List discovered skillsShow all skills found in the repository.
# Simple list (name + path)
madskills list
# Include all metadata
madskills list --long
# JSON output
madskills list --format json
madskills init - Scaffold a new skillCreate a new skill directory with template files. Auto-detects the appropriate location (see Skill Discovery below).
# Create skill (auto-detects location)
madskills init my-skill
# Custom description
madskills init my-skill --description "Process PDF documents"
# Override auto-detection with explicit location
madskills init my-skill --dir path/to/custom/location
madskills fmt - Format skill filesFormats both YAML frontmatter and markdown content.
# Format all skills (frontmatter + markdown)
madskills fmt
# Check mode (don't write, exit 2 if changes needed)
madskills fmt --check
# Only frontmatter normalization (skip markdown)
madskills fmt --no-mdlint
# Only markdown formatting (skip frontmatter)
madskills fmt --no-frontmatter
# Custom markdown linting config
madskills fmt --mdlint-config path/to/config.toml
-C, --chdir <DIR> Run as if started in DIR
-q, --quiet Only print errors
-v, --verbose More detail (repeatable: -vv)
--color <WHEN> Colorize output: auto|always|never
madskills automatically detects where skills are located using a priority-based algorithm:
AGENT_SKILLS_DIR environment variable - If set and exists, uses this directory/skills pattern in AGENTS.md (e.g., .claude/skills/, ~/agent-skills/).github/skills/.claude/skills/.codex/skills/.github/ exists → .github/skills/./skills/Override detection:
# Set environment variable for all commands
export AGENT_SKILLS_DIR=~/my-skills
madskills lint
# Use --dir flag for init command
madskills init my-skill --dir custom/path/my-skill
Note: Home directory (~) expansion is supported in AGENTS.md and AGENT_SKILLS_DIR.
The lint command validates:
--)# .github/workflows/skills.yml
name: Validate Skills
on: [push, pull_request]
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- run: cargo install madskills
- run: madskills lint --strict --format json
#!/bin/bash
# .git/hooks/pre-commit
madskills lint --strict
madskills list --format json | jq '.[] | select(.license == null) | .name'
# Check compilation
just check
# Run tests
just test
# Run all checks (fmt, clippy, test, doc-test)
just check
# Coverage report
just cov
madskills/
├── crates/
│ ├── madskills/ # CLI binary
│ └── madskills-core/ # Core library (discovery, parsing, validation, markdown, best practices)
├── PLAN.md # Implementation specification
└── README.md
Contributions welcome! Please see AGENTS.md for development conventions.
Licensed under either of Apache License, Version 2.0 or MIT license at your option.