docs: Update slash commands documentation with official features
- Add comprehensive built-in commands reference (40+ commands) - Document argument handling ($ARGUMENTS, $1, $2, etc.) - Add bash execution syntax (! prefix) and file references (@ prefix) - Update frontmatter to official fields (allowed-tools, argument-hint, model, etc.) - Add Plugin Commands and MCP Slash Commands sections - Add SlashCommand Tool documentation for programmatic invocation - Add Skills vs Slash Commands comparison table - Create commit.md example with bash execution and context - Update existing examples to use official frontmatter format - Add OpenSpec proposal for change tracking
This commit is contained in:
26
01-slash-commands/commit.md
Normal file
26
01-slash-commands/commit.md
Normal file
@@ -0,0 +1,26 @@
|
||||
---
|
||||
allowed-tools: Bash(git add:*), Bash(git status:*), Bash(git commit:*), Bash(git diff:*)
|
||||
argument-hint: [message]
|
||||
description: Create a git commit with context
|
||||
---
|
||||
|
||||
## Context
|
||||
|
||||
- Current git status: !`git status`
|
||||
- Current git diff: !`git diff HEAD`
|
||||
- Current branch: !`git branch --show-current`
|
||||
- Recent commits: !`git log --oneline -10`
|
||||
|
||||
## Your task
|
||||
|
||||
Based on the above changes, create a single git commit.
|
||||
|
||||
If a message was provided via arguments, use it: $ARGUMENTS
|
||||
|
||||
Otherwise, analyze the changes and create an appropriate commit message following conventional commits format:
|
||||
- `feat:` for new features
|
||||
- `fix:` for bug fixes
|
||||
- `docs:` for documentation changes
|
||||
- `refactor:` for code refactoring
|
||||
- `test:` for adding tests
|
||||
- `chore:` for maintenance tasks
|
||||
Reference in New Issue
Block a user