From dh-skills
Create a GitHub pull request from staged changes — creates a new branch, commits the staged work, and opens a PR into main, always linked to a Linear ticket. Crafts a [DEV-123] <type>: title and a Summary / bullets / Test plan body, opens the PR with gh, and attaches it to the Linear issue both ways. Use when the user asks to "open a PR", "create a github pr", "raise a pull request", or "PR this into main".
How this skill is triggered — by the user, by Claude, or both
Slash command
/dh-skills:create-github-prThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Takes the current **staged changes** (`git add`'d files), creates a new feature branch, commits
Takes the current staged changes (git add'd files), creates a new feature branch, commits
the work, pushes, and opens a PR into main — always linked to a Linear ticket (existing or
freshly created) so the two are navigable from each other.
⚠️ MANUAL ONLY — This skill runs ONLY when you explicitly ask to open a PR. It will never auto-trigger.
| Arg | Required | Description |
|---|---|---|
| ticket number | No | An existing Linear ticket ID (e.g. DEV-123) to link. If omitted, the ticket is resolved or created (step 2). |
| context | No | Extra context about the change — e.g. the reason, motivation, or any details to weave into the PR title/body. |
Note: The branch name is always asked interactively (type one or let the skill auto-generate it).
CRITICAL: Plan first, execute only after approval. Steps 1–5 are READ-ONLY planning. Do NOT create branches, commits, tickets, or PRs until the user explicitly approves the plan in step 5. The only action allowed before approval is reading the staged diff and asking questions.
git diff --cached --stat to confirm there are staged changes.git add the files they want in the PR.git diff --cached) to understand the scope of changes.The PR must be linked to a Linear ticket. Resolve one in this priority order:
mcp__linear__get_issue and use it.If a ticket is found, confirm it with mcp__linear__get_issue (title + state) and reuse it.
If no ticket is found, ask the user:
Do NOT create the ticket yet. Just note the decision.
git diff --cached --stat -- . ':!*.spec.*' ':!*.test.*' ':!pnpm-lock.yaml' ':!package-lock.json' ':!yarn.lock'Title — conventional-commit form, prefixed with the ticket:
[DEV-123] <type>: <concise description>
feat, fix, refactor, docs, test, chore, perf, ci.Body — the established repo format (literal newlines, not \n):
Summary
<One-sentence overview of what the PR adds / changes / removes.>
<Bullet points expanding on the specific changes — what was added, removed, or restructured.
Capture intent and scope, not line-by-line implementation detail.
If a **context** argument was provided, incorporate the motivation/reason naturally into the
summary and bullets.>
Test plan
- [ ] <Verification step 1>
- [ ] <Verification step 2 (if needed)>
Ask the user: "What should the branch be?" and present two options:
<date>_<ticket-lower>_<slug> e.g. 06-03_dev-621_fix-drizzle-journalShow the user a clear summary of everything that will happen and wait for explicit approval before taking ANY action:
📋 PR PLAN (nothing created yet)
─────────────────────────────────────────
Ticket: DEV-621 (existing) / "will create: <title>"
Branch: 06-03_dev-621_fix-drizzle-journal (will be created off main)
Type: fix
Title: [DEV-621] fix: register migrations 0023/0024 in drizzle journal
Staged: 3 files, +48 -2
Body:
Summary
Registers the missing 0023/0024 migrations in the drizzle journal so
db:migrate applies them in order.
...
Test plan
- [ ] ...
Actions that will be taken on approval:
1. Create Linear ticket (if needed)
2. Stash staged changes
3. Checkout main, pull latest
4. Create branch: 06-03_dev-621_fix-drizzle-journal
5. Pop stash, commit, push
6. Open PR into main
7. Link PR ↔ Linear ticket
Ready to execute? (yes/no)
If the user declines, ask what to change (title, body, ticket, scope) and revise the plan. Do NOT proceed until the user says yes.
linear-ticket-create now.identifier and url.This step ensures the PR branch always forks directly off main, regardless of the current
branch state:
git stash push --staged -m "pr-staged-changes"git checkout main && git pull --ff-onlygit checkout -b <branch-name>git stash popgit add -A (or re-add the specific files)git commit -m "[DEV-123] <type>: <concise description>"git push -u origin HEADAlways targets main:
gh pr create \
--base "main" \
--title "[DEV-123] <type>: <description>" \
--body "$(cat <<'EOF'
Summary
...
Test plan
- [ ] ...
EOF
)"
Capture the PR number and URL from the command output (or gh pr view --json number,url).
mcp__linear__create_attachment with issueId (the ticket), url = the PR URL, and a
title like PR #<number>: <pr title>.[DEV-123] prefix on the PR title is the other half of the link — confirm it's present.In Review), do it on request via mcp__linear__save_issue.url.url.main.[DEV-510] feat: make sub-deal rows clickable with actions column
Summary
Makes each sub-deal row navigate to its detail view and adds an actions column.
Wrap sub-deal reference cells in a link to the sub-deal route.
Add an actions column with per-row controls.
Keep row click and action buttons from conflicting.
Test plan
- [ ] Click a sub-deal row and confirm it opens the correct sub-deal
- [ ] Use an action button and confirm the row does not also navigate
[DEV-621] fix: register migrations 0023/0024 in drizzle journal
Summary
Registers the missing 0023/0024 migrations in the drizzle journal so db:migrate
applies them in order.
Add the 0023 and 0024 entries to drizzle/meta/_journal.json.
Regenerate the matching snapshot files.
Test plan
- [ ] Run npm run db:migrate on a clean DB and confirm 0023/0024 apply
- [ ] Confirm drizzle-kit reports no pending or out-of-order migrations
[DEV-507] refactor: extract parseDateParam helper and thread settlement date through PDF endpoints
Summary
Extracts a shared parseDateParam helper and threads the settlement date through the PDF
export endpoints.
Add parseDateParam to centralise query-date parsing and validation.
Pass the parsed settlement date into each PDF export route.
Remove the duplicated inline date parsing.
Test plan
- [ ] Export a PDF with a settlement date query param and confirm it renders
- [ ] Omit the param and confirm the endpoint falls back correctly
git diff --cached). Stage your files first, then invoke this skill.main.main.[DEV-123], so
each is reachable from the other.gh pr create.ONLY when you explicitly ask to open a PR. This skill is manual and does not auto-trigger. Examples of explicit requests:
It will NEVER run unless you explicitly invoke it or ask to create a PR.
linear-ticket-create — turn loose input into a Triage-ready ticket; used by step 2 when no
ticket exists yet.pr-to-linear-ticket — the reverse/repair flow: back-fill a ticket for an already-open PR
and stamp its title.npx claudepluginhub developer-hut/marketplace --plugin dh-skillsProvides a checklist for code reviews covering functionality, security, performance, maintainability, tests, and quality. Use for pull requests, audits, team standards, and developer training.