Git context injection for Workshop agents.
When git_context: true is set in configure/1, a summary of the
current git state is automatically appended to every agent's system
prompt. Agents always know what branch they're on, what's changed,
and recent commit history.
Usage
configure(git_context: true)What's injected
- Current branch and tracking info
- Dirty/clean status
- Staged and unstaged file counts
- Last 5 commit subjects
- Uncommitted file list (if dirty)
Summary
Functions
Build a git context string for the current working directory.
Get uncommitted changes as a formatted string.
Get a structured summary of the current git state.
Functions
Build a git context string for the current working directory.
Returns a formatted string suitable for appending to an agent's
system prompt, or nil if git info is unavailable.
Get uncommitted changes as a formatted string.
Get a structured summary of the current git state.
Returns a map with branch, status, recent commits, and file changes.