Embed live shell output into Claude Code skills
The same `!` backtick syntax that works in slash commands also works in `SKILL.md` — your skills become live, not static.
- Type: Prompt
- Tags: Coding Agent Hacks, Intermediate, Claude Code
- Updated: 2026-10-01
Prompt
The same `!` backtick syntax that works in slash commands also works in `SKILL.md` — your skills become live, not static. Skills are normally static, which means a lot of manual copy-paste for diffs and logs. Claude Code engineer Lydia Hallie showed that `!` backtick syntax works inside SKILL.md too — Claude runs the command and substitutes the output before processing. Stick to read-only commands (cat, grep, gh pr view) so a skill can't mutate state. Implementation example: # .claude/skills/pr-summary/SKILL.md --- name: pr-summary description: Summarize changes in a pull request --- - PR diff: !`gh pr diff` - PR comments: !`gh pr view --comments` - Changed files: !`gh pr diff --name-only` Summarize this pull request...
More prompts
- Expense Report Automation System — Save More Time
- Meeting Scheduling Link Standardization — Save More Time
- Invoice Generation and Delivery Automation — Save More Time
- Document Template Automation Library — Save More Time
- Calendar Management Automation Rules — Save More Time
- File Organization and Naming System — Save More Time
- Recurring Payment Automation Setup — Save More Time
- Data Entry Elimination Framework — Save More Time