agent coding workflow risk: high
Linear Issue Git Branch PR Creator
The prompt instructs the model to resolve a Linear issue by fetching its context using Linear MCP, creating a new git branch named claude/<ISSUE ID>-<short description>, researchin…
- Policy sensitive
- Human review
- External action: high
PROMPT
--- name: work-on-linear-issue description: You will receive a Linear issue id usually on the the form of LLL-XX... where Ls are letters and Xs are digits. Your job is to resolve it on a new branch and open a PR to the branch main. --- You should follow these steps: 1. Use the Linear MCP to get the context of the issue, the issue number is at $0. 2. Start on the latest version of main, do a pull if necesseray. Then create a new branch in the format of claude/<ISSUE ID>-<SHORT 3-4 WORD DESCRIPTION OF THE ISSUE> checkout to this new branch. All your changes/commits should happen on the new branch. 3. Do your research of the codebase with respect to the info of the issue and come up with an implementation plan. While planning if you have any confusions ask for clarifications. Enter to planning after every verification step. 4. Implement while commiting along the way, following git commit best practices. 5. After you think you are done with the issue, with a clear fresh new perspective, re-look at your changes to identify possible issues, bugs, or edge cases. If there is any address them. 6. After you are confident that you have implemented the changes without problems, bugs, etc. create a PR to the main branch.
INPUTS
- $0 REQUIRED
-
Linear issue id usually in the form LLL-XX
e.g. ENG-123
REQUIRED CONTEXT
- Linear issue id
TOOLS REQUIRED
- Linear MCP
EXPECTED OUTPUT
- Format
- unknown
SUCCESS CRITERIA
- Resolve the Linear issue on a new branch
- Create a PR to the main branch
- Follow the specified steps including research, implementation, review
FAILURE MODES
- May work on incorrect branch
- Might skip pulling latest main
- Could overlook bugs or edge cases in review
- May not ask for clarifications when confused
CAVEATS
- Dependencies
-
- Linear issue ID at $0
- Linear MCP for issue context
- Git repository access for branching, committing, and PR creation
- Missing context
-
- Definition or access instructions for 'Linear MCP'.
- Repository access details (e.g., clone URL, auth).
- Codebase-specific conventions beyond git.
- PR details like title format, description requirements.
- Ambiguities
-
- 'Linear MCP' is not defined or explained.
- 'Enter to planning after every verification step' – verification steps not specified.
- 'open a PR to the branch main' likely means 'to the main branch'.
QUALITY
- OVERALL
- 0.75
- CLARITY
- 0.80
- SPECIFICITY
- 0.70
- REUSABILITY
- 0.90
- COMPLETENESS
- 0.70
IMPROVEMENT SUGGESTIONS
- Fix typos: 'necesseray' to 'necessary', 'checkout to this new branch' to 'check out the new branch'.
- Clarify 'Linear MCP' usage, e.g., 'Use the Linear MCP tool with issue id $0 to fetch details'.
- Define 'verification steps' or remove vague reference.
- Specify PR creation details: title using issue title, body with implementation notes.
- Add success criteria: e.g., 'PR must pass CI, include tests if applicable'.
USAGE
Copy the prompt above and paste it into your AI of choice — Claude, ChatGPT, Gemini, or anywhere else you're working. Replace any placeholder sections with your own context, then ask for the output.
MORE FOR AGENT
- Rapid App MVP Prototyperagentcoding
- AI-First Design Handoff Specs Generatoragentcoding
- Structured Autonomy Implementation Agentagentcoding
- PROGRESS.md Manager for Agentic Codingagentcoding
- Code Second Opinion from Gemini and Codexagentcoding
- Travel Booking Web App Builderagentcoding
- Comprehensive Codebase Bug Analysis and Fixeragentanalysis
- Xcode MCP Usage Guidelines for Agentsagenttool_use
- Xcode MCP Usage Guidelinesagenttool_use
- Local Documentation Online Sync Automatoragentoperations