Analyze issue and create PR delivery strategy before coding
Analyzes Jira issues to generate a pull request delivery strategy before coding begins.
/plugin marketplace add markus41/claude/plugin install jira-orchestrator@claude-orchestrationGenerate a proactive PR delivery strategy for a Jira issue BEFORE coding begins.
AUTOMATIC: This step runs silently before command execution begins.
The orchestration system tracks execution time for this command. When the command completes:
[Claude] /jira:plan-prs - {duration}${issue_key})feature/PROJ-123-desc)JIRA_ISSUE_KEYTime logging can be configured in jira-orchestrator/config/time-logging.yml:
enabled: Toggle auto-logging (default: true)threshold_seconds: Minimum duration to log (default: 60)format: Worklog comment format (default: "[Claude] {command} - {duration}")Large PRs are hard to review and often lead to:
This command helps by planning how to split work into small, reviewable PRs upfront.
Fetches Issue Details
Estimates PR Size
Creates Splitting Strategy
Posts Plan to Jira
Configures Orchestration
/jira:work/jira:plan-prs ISSUE-KEY
š PR Size Estimation Complete
Parent Issue: PROJ-123
Total Estimated: ~1,450 lines (š“ Large - Split Required)
Strategy: 3-PR Split (Sub-Item Based)
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā PR #1: [PROJ-123] Part 1: Database Layer ā
ā āā Sub-Items: PROJ-201, PROJ-202 ā
ā āā Est. Size: ~350 lines ā
ā āā Dependencies: None ā
ā āā Merge Order: First ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤
ā PR #2: [PROJ-123] Part 2: API Layer ā
ā āā Sub-Items: PROJ-203, PROJ-204, PROJ-205 ā
ā āā Est. Size: ~600 lines ā
ā āā Dependencies: PR #1 ā
ā āā Merge Order: After PR #1 merges ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤
ā PR #3: [PROJ-123] Part 3: UI Components ā
ā āā Sub-Items: PROJ-206, PROJ-207 ā
ā āā Est. Size: ~500 lines ā
ā āā Dependencies: PR #2 ā
ā āā Merge Order: Final ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā
Strategy posted to Jira: https://jira.company.com/browse/PROJ-123
ā
Configuration saved for CODE phase agents
ā
Work plan artifact saved: `.claude/orchestration/plans/PROJ-123-plan.json`
Next Steps:
1. Run /jira:work PROJ-123 to start development
2. Checkpoint PRs will be created automatically
3. Each PR stays under 400 lines for easy review
| Total Lines | Strategy | What Happens |
|---|---|---|
| < 200 | Single PR | ā Proceed normally |
| 200-400 | Single PR with roadmap | ā ļø Create review chunks |
| 400-800 | Split into 2-3 PRs | š Split recommended |
| > 800 | Split into 3+ PRs | š“ Split required |
graph TD
A[/jira:plan-prs ISSUE-KEY] --> B[Fetch Issue from Jira]
B --> C[Get Sub-Items]
C --> D[Analyze Complexity]
D --> E{Estimated Size?}
E -->|< 400 lines| F[Single PR Strategy]
E -->|400-800 lines| G[2-3 PR Strategy]
E -->|> 800 lines| H[3+ PR Strategy]
F --> I[Generate Report]
G --> I
H --> I
I --> J[Post to Jira]
J --> K[Save Config + Work Plan Artifact]
K --> L[Ready for /jira:work]
This command invokes the pr-size-estimator agent which:
Environment variables to customize behavior:
# Size thresholds
PR_WARN_THRESHOLD=400 # Warn above this many lines
PR_BLOCK_THRESHOLD=800 # Require split above this
# Strategy preferences
PR_SPLIT_STRATEGY=auto # auto, sub_item, layer, feature_slice
PR_MAX_SIZE=400 # Target max size per PR
This command works with:
/jira:work: Uses the strategy during CODE phase/jira:work: Loads the work plan artifact to adapt phase staffing, gating, and PR splits/jira:plan-prs writes a JSON artifact to .claude/orchestration/plans/{ISSUE-KEY}-plan.json.
/jira:work must load this file before task breakdown to enforce scope, sequencing, and PR splits.
{
"issue_key": "PROJ-123",
"estimated_total_loc": 1450,
"pr_strategy": "sub_item",
"max_pr_size": 400,
"pr_splits": [
{"name": "Database Layer", "sub_items": ["PROJ-201", "PROJ-202"], "dependencies": []},
{"name": "API Layer", "sub_items": ["PROJ-203"], "dependencies": ["Database Layer"]}
],
"gates": {
"max_parallel_prs": 2,
"required_reviewers": ["backend-architect", "api-security-expert"]
}
}
Run this command:
/jira:work - Start full orchestration (uses this strategy)/jira:pr - Create PR (respects size guard)/jira:status - Check current orchestration statusPhilosophy: "The best time to split a PR is before you write the code."