Implement fixes for GitHub issues in isolated worktrees with testing and commit automation
Implements GitHub issue fixes in isolated worktrees with automated testing, committing, and pushing.
/plugin marketplace add randlee/synaptic-canvas/plugin install sc-github-issue@synaptic-canvassonnetThis agent is invoked via the Claude Task tool by a skill or command. Do not invoke directly.
Execute the core fix workflow:
{
"issue_number": 42,
"issue_title": "Application crashes on startup",
"issue_body": "Detailed description of the problem...",
"repo": "owner/repo",
"worktree_path": "/path/to/worktree",
"branch": "fix-issue-42",
"yolo": false,
"config": {
"base_branch": "main",
"test_command": "npm test",
"commit_pattern": "Fix #{number}: {title}"
}
}
Fields:
issue_number: Required. Issue number being fixedissue_title: Required. Issue title for commit messageissue_body: Required. Detailed issue descriptionrepo: Required. Repository in "owner/repo" formatworktree_path: Required. Absolute path to worktree directorybranch: Required. Branch name for the fixyolo: Optional. Skip test failure prompts if true (default: false)config: Configuration settings
base_branch: Base branch nametest_command: Command to run tests (null if no tests)commit_pattern: Pattern for commit messageReturn fenced JSON with minimal envelope:
```json
{
"success": true,
"data": {
"issue_number": 42,
"branch": "fix-issue-42",
"worktree_path": "/path/to/worktree",
"commits": [
{
"sha": "abc123def456",
"message": "Fix #42: Application crashes on startup"
}
],
"tests_passed": true,
"test_output": "All tests passed (15/15)",
"files_changed": [
"src/startup.ts",
"tests/startup.test.ts"
],
"pushed": true
},
"error": null
}
```
On Error:
```json
{
"success": false,
"data": null,
"error": {
"code": "WORKTREE.DIRTY",
"message": "Uncommitted changes in worktree",
"recoverable": true,
"suggested_action": "Commit or stash changes before running fix workflow"
}
}
```
cd "$worktree_path"test_command configured, run: bash -c "$test_command"yolo:
tests_passed based on exit codegit add .{number} with issue number{title} with issue titlegit commit -m "$message"git push -u origin "$branch"git rev-parse HEADgit diff --name-only HEAD~1WORKTREE.DIRTY - Uncommitted changes before fixWORKTREE.NOT_FOUND - Worktree path does not existEXEC.TEST_FAILED - Tests failed and user abortedGIT.COMMIT_FAILED - Git commit failedGIT.PUSH_FAILED - Git push failed (network, permissions, etc.)IMPL.UNCERTAIN - Unable to determine fix approachyolo modeFor complex issues spanning multiple files:
Successful fix:
{
"issue_number": 42,
"issue_title": "Application crashes on startup",
"issue_body": "TypeError when initializing config module",
"repo": "anthropics/claude-code",
"worktree_path": "/path/to/worktrees/fix-issue-42",
"branch": "fix-issue-42",
"yolo": false,
"config": {
"base_branch": "main",
"test_command": "npm test",
"commit_pattern": "Fix #{number}: {title}"
}
}
Output:
{
"success": true,
"data": {
"issue_number": 42,
"branch": "fix-issue-42",
"worktree_path": "/path/to/worktrees/fix-issue-42",
"commits": [
{
"sha": "abc123def456",
"message": "Fix #42: Application crashes on startup"
}
],
"tests_passed": true,
"test_output": "15 passed, 0 failed",
"files_changed": ["src/config.ts", "tests/config.test.ts"],
"pushed": true
},
"error": null
}
Designs feature architectures by analyzing existing codebase patterns and conventions, then providing comprehensive implementation blueprints with specific files to create/modify, component designs, data flows, and build sequences