.meta({ deprecated: true }). Deprecated flags show [deprecated] in --help, **Deprecated.** in skill docs, deprecated: true in JSON Schema (--llms), and emit a stderr warning when used in TTY mode.
Basic Usage
Help Text
Deprecated options show[deprecated] in help output:
Skill Documentation
Skill files (generated byskills add) include **Deprecated.** for deprecated options:
JSON Schema
--llms output includes deprecated: true in the JSON Schema:
Runtime Warnings
When a deprecated flag is used in human/TTY mode, incur emits a warning to stderr:--json, piped output, MCP) do not emit warnings.
Migration Patterns
Renaming an Option
Removing an Option
Deprecate first, remove later:Replacing with a Different Type
Short Aliases
Deprecated options also apply to their short aliases:Boolean Flags
Deprecation warnings apply to both--flag and --no-flag forms:
Documentation Flow
Deprecation annotations flow through all output formats:| Format | Annotation |
|---|---|
--help | [deprecated] suffix |
skills add | **Deprecated.** prefix |
--llms --format json | "deprecated": true |
--llms --format md | **Deprecated.** prefix |
| TTY usage | stderr warning |
Best Practices
Do
- Mark options as deprecated before removing them
- Provide migration guidance in the description
- Support both old and new options during the transition period
- Remove deprecated options in a major version bump
Don’t
- Don’t mark required options as deprecated — make them optional first
- Don’t remove deprecated options without a deprecation period
- Don’t rely on deprecated options in examples or documentation

