init Command
Initializeskill-project.toml for skill authors. This command creates a project manifest file for managing skill metadata, dependencies, and version information.
Usage
Options
| Option | Description | Default |
|---|---|---|
--yes | Skip interactive prompts and use defaults | false |
--force | Force reinitialization even if skill-project.toml exists | false |
--version <VERSION> | Set version directly | None |
--description <DESC> | Set skill description | None |
--author <AUTHOR> | Set skill author | None |
--download-url <URL> | Set download URL | None |
Examples
Interactive Initialization
Run interactively with prompts for all required fields:- Version (defaults to 1.0.0)
- Description (optional)
- Author (optional)
- Download URL (optional)
Non-Interactive Initialization
Use--yes to skip prompts and use defaults:
Set All Fields Non-Interactively
Set all fields via command-line options:Force Reinitialization
Overwrite existingskill-project.toml:
Behavior
Theinit command:
- Detects Context: Determines if you’re in a skill directory (with SKILL.md) or a project directory
- Extracts Metadata: If SKILL.md exists, extracts version, description, and author from YAML frontmatter
- Prioritizes Inputs: Uses values in this priority order:
- CLI arguments (highest priority)
- SKILL.md frontmatter
- Interactive prompts
- Default values (lowest priority)
- Generates Skill ID: Uses the current directory name as the skill ID
- Validates Format: Validates skill ID format and semantic version format
- Creates File: Writes
skill-project.tomlwith basic structure and commented examples
Generated File Structure
Theinit command creates a skill-project.toml file with the following structure:
skill-project.toml
Skill ID Detection
The skill ID is automatically derived from the current directory name:If you’re in a project directory (no SKILL.md), the
skill-project.toml can still be used to declare dependencies for installation via fastskill install.Context Detection
The command automatically detects the project context:Skill Context (with SKILL.md)
WhenSKILL.md exists in the current directory:
skill-project.toml includes metadata that augments or overrides SKILL.md frontmatter for publishing.
Project Context (without SKILL.md)
When noSKILL.md exists:
fastskill install to install skills declared in [dependencies] section.
SKILL.md Frontmatter Integration
WhenSKILL.md exists, the command extracts metadata from YAML frontmatter:
SKILL.md
If you provide
--version, --description, or --author flags, they will override the values from SKILL.md frontmatter.Version Validation
The command validates semantic version format: Valid versions:1.0.02.1.30.0.110.20.30
1.0(missing patch)1(missing minor and patch)v1.0.0(v prefix not allowed)1.0.0-beta(pre-release not supported in init)
Skill ID Validation
The skill ID (directory name) must meet these requirements:- Must start with a letter
- Can contain letters, numbers, hyphens, and underscores
- Cannot contain spaces or special characters
- Cannot start or end with hyphen or underscore
my-skilldata_processorweb-scraper-v2
my skill(contains space)-skill(starts with hyphen)skill_(ends with underscore)123skill(doesn’t start with letter)
Workflow Examples
Creating a New Skill
Creating a Multi-Skill Project
Updating Metadata for Existing Skill
Use Cases
For Skill Authors
Usefastskill init to:
- Create project metadata for publishing skills
- Track skill versions independent of SKILL.md
- Override SKILL.md frontmatter for publishing
- Add download URLs for distribution
For Project Maintainers
Usefastskill init to:
- Declare skill dependencies in
[dependencies]section - Configure repositories in
[tool.fastskill.repositories] - Set up reproducible installations via
fastskill install
For CI/CD Pipelines
Usefastskill init --yes to:
- Create manifests without interactive prompts
- Generate consistent metadata across environments
- Automate project setup
See Also
- Install Command - Install skills from skill-project.toml
- Package Command - Package skills for distribution
- Publish Command - Publish skills to registries
- Configuration Guide - Complete configuration reference