Format git commit messages correctly, avoiding HEREDOC syntax issues in favor of multiline strings
/plugin marketplace add boneskull/claude-plugins/plugin install skill-activation@boneskull-pluginsThis skill inherits all available tools. When active, it can use any tool Claude has access to.
Use this skill when creating git commits with the Bash tool, especially for commits with:
Avoid HEREDOC syntax - Use -m with multiline strings instead.
git commit -m "feat(github): add github plugin
This adds comprehensive GitHub workflow support including
commands for PR management and review workflows.
š¤ Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>"
Key points:
-m flag with entire message in quotes# This FAILS in Claude Code's Bash tool
git commit -m "$(cat <<'EOF'
feat(github): add github plugin
This adds comprehensive GitHub workflow support.
š¤ Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
EOF
)"
Why this fails:
git commit -m "fix: resolve path configuration issue"
git commit -m "feat: add progressive disclosure pattern
Skills now support references/ subdirectory for
detailed documentation that loads on-demand."
git commit -m "chore: update dependencies
š¤ Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>"
git commit -m "feat(tools): add git commit message skill
This skill teaches Claude to format git commit messages
using multiline strings instead of HEREDOC syntax, which
fails in certain shell environments.
The pattern uses a single -m flag with the entire message
in quotes, preserving newlines naturally.
š¤ Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>"
Using -m with multiline strings is:
HEREDOC syntax causes issues because:
Template for commits with Claude Code attribution:
git commit -m "<type>[optional scope]: <description>
[optional body]
š¤ Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>"
Remember:
-m flagThis skill should be used when the user asks to "create an agent", "add an agent", "write a subagent", "agent frontmatter", "when to use description", "agent examples", "agent tools", "agent colors", "autonomous agent", or needs guidance on agent structure, system prompts, triggering conditions, or agent development best practices for Claude Code plugins.
This skill should be used when the user asks to "create a slash command", "add a command", "write a custom command", "define command arguments", "use command frontmatter", "organize commands", "create command with file references", "interactive command", "use AskUserQuestion in command", or needs guidance on slash command structure, YAML frontmatter fields, dynamic arguments, bash execution in commands, user interaction patterns, or command development best practices for Claude Code.
This skill should be used when the user asks to "create a hook", "add a PreToolUse/PostToolUse/Stop hook", "validate tool use", "implement prompt-based hooks", "use ${CLAUDE_PLUGIN_ROOT}", "set up event-driven automation", "block dangerous commands", or mentions hook events (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification). Provides comprehensive guidance for creating and implementing Claude Code plugin hooks with focus on advanced prompt-based hooks API.