/pr-create
Create a pull request with auto-detected context
$ npx -y skills add huangjia2019/claude-code-engineering --agent claude-codeHow it fires
How this command gets triggered: by you, by Claude, or both.
- Fires itselfClaude auto-loads it when your prompt matches the work.
- You can call itInvoke it directly when you want it.
- Slash command
/pr-create
Context preview
What this command does when you run it.
Create a pull request with auto-detected context
Command definition
pr-create.mddescription: Create a pull request with auto-detected context argument-hint: [title] [description] allowed-tools: Bash(git:*), Bash(gh:*)
Create a pull request.
Title: $1 Description: $2
Current Context (Auto-detected)
Current branch: !`git branch --show-current`
Recent commits on this branch: !`git log origin/main..HEAD --oneline 2>/dev/null || echo "No commits ahead of main"`
Files changed: !`git diff --stat origin/main 2>/dev/null || git diff --stat HEAD~3`
Steps
1. Ensure we're not on main/master branch 2. Push current branch to remote (if not already) 3. Create PR using `gh pr create`:
- Title: $1 (or auto-generate from branch name)
- Body: $2 (or auto-generate from commits)
4. Return the PR URL
PR Body Template
If $2 is not provided, generate:
## Summary [Auto-generated from commit messages] ## Changes [List of changed files with brief descriptions] ## Testing - [ ] Tests pass locally - [ ] Manual testing completed --- Created with `/pr-create`
Output
✓ PR Created: [URL] Title: [title] Branch: [branch] → main Changes: [n] files
This repository demonstrates how to use Claude Code to do real engineering work, not just writing code. 本项目是极客时间专栏 《Claude Code 工程化实战》 的官方配套示例仓库,目标就是: 👉 把 Claude Code 从“对话式编码工具”,变成 可设计、可复用、可治理的工程系统。
Other commands on claude-code-engineering.
- /commit
Quick git commit with auto-generated or specified message
Open command - /explain
Explain code in simple, beginner-friendly terms
Open command - /log
Show recent git history with summary
Open command - /status
Show git status with helpful context
Open command - /review
对代码进行全面审查,输出结构化报告
Open command - /todo
Add a TODO comment to code with optional priority and assignee
Open command

