Initial commit
This commit is contained in:
11
.claude-plugin/plugin.json
Normal file
11
.claude-plugin/plugin.json
Normal file
@@ -0,0 +1,11 @@
|
||||
{
|
||||
"name": "pr-create-plugin",
|
||||
"description": "Create GitHub pull requests with auto-generated title and description based on branch changes",
|
||||
"version": "1.0.0",
|
||||
"author": {
|
||||
"name": "Stefan Cho"
|
||||
},
|
||||
"commands": [
|
||||
"./commands"
|
||||
]
|
||||
}
|
||||
3
README.md
Normal file
3
README.md
Normal file
@@ -0,0 +1,3 @@
|
||||
# pr-create-plugin
|
||||
|
||||
Create GitHub pull requests with auto-generated title and description based on branch changes
|
||||
52
commands/pr-create.md
Normal file
52
commands/pr-create.md
Normal file
@@ -0,0 +1,52 @@
|
||||
---
|
||||
description: Create PR with auto-generated title and description
|
||||
allowed-tools: Bash(git status:*), Bash(git log:*), Bash(git diff:*), Bash(git push:*), Bash(gh pr create:*)
|
||||
---
|
||||
|
||||
Create a pull request by following these steps:
|
||||
|
||||
1. Run these commands in parallel to understand the current state:
|
||||
- `git status` - Check branch status and tracking
|
||||
- `git log origin/main..HEAD --oneline` - See commits that will be in the PR
|
||||
- `git diff origin/main...HEAD` - See all changes compared to origin's main branch
|
||||
|
||||
2. Analyze all changes and commits to draft:
|
||||
- PR title: Concise summary following the repo's commit message style
|
||||
- PR body with this format:
|
||||
```
|
||||
## Summary
|
||||
- [Bullet point 1]
|
||||
- [Bullet point 2]
|
||||
- [Bullet point 3]
|
||||
|
||||
## Test plan
|
||||
- [ ] [Test step 1]
|
||||
- [ ] [Test step 2]
|
||||
|
||||
🤖 Generated with [Claude Code](https://claude.com/claude-code)
|
||||
```
|
||||
|
||||
3. Push current branch to origin with `-u` flag if needed
|
||||
|
||||
4. Create PR using:
|
||||
```bash
|
||||
gh pr create --title "PR title here" --body "$(cat <<'EOF'
|
||||
## Summary
|
||||
- Point 1
|
||||
- Point 2
|
||||
|
||||
## Test plan
|
||||
- [ ] Step 1
|
||||
|
||||
🤖 Generated with [Claude Code](https://claude.com/claude-code)
|
||||
EOF
|
||||
)"
|
||||
```
|
||||
|
||||
5. Return the PR URL when done
|
||||
|
||||
IMPORTANT:
|
||||
- Compare with origin/main (not local main)
|
||||
- Review ALL commits from branch point, not just latest commit
|
||||
- Keep title concise and descriptive
|
||||
- Make summary bullets focus on "why" not just "what"
|
||||
45
plugin.lock.json
Normal file
45
plugin.lock.json
Normal file
@@ -0,0 +1,45 @@
|
||||
{
|
||||
"$schema": "internal://schemas/plugin.lock.v1.json",
|
||||
"pluginId": "gh:devstefancho/claude-plugins:pr-create-plugin",
|
||||
"normalized": {
|
||||
"repo": null,
|
||||
"ref": "refs/tags/v20251128.0",
|
||||
"commit": "9e972d2f1a75455b8fc43f1b1c578d8be358152d",
|
||||
"treeHash": "5106bb57dcf0fc1af391775dbb1d83850bd0fadeca32181f8c1e104c6808a7de",
|
||||
"generatedAt": "2025-11-28T10:16:21.902710Z",
|
||||
"toolVersion": "publish_plugins.py@0.2.0"
|
||||
},
|
||||
"origin": {
|
||||
"remote": "git@github.com:zhongweili/42plugin-data.git",
|
||||
"branch": "master",
|
||||
"commit": "aa1497ed0949fd50e99e70d6324a29c5b34f9390",
|
||||
"repoRoot": "/Users/zhongweili/projects/openmind/42plugin-data"
|
||||
},
|
||||
"manifest": {
|
||||
"name": "pr-create-plugin",
|
||||
"description": "Create GitHub pull requests with auto-generated title and description based on branch changes",
|
||||
"version": "1.0.0"
|
||||
},
|
||||
"content": {
|
||||
"files": [
|
||||
{
|
||||
"path": "README.md",
|
||||
"sha256": "667ab6e57c79e722851dbde271681510e8d352926784cf6e880afe110782f05d"
|
||||
},
|
||||
{
|
||||
"path": ".claude-plugin/plugin.json",
|
||||
"sha256": "25b4ed770a7efb4280a153d764180614a22382a819c013e6b352dd1b457c0e60"
|
||||
},
|
||||
{
|
||||
"path": "commands/pr-create.md",
|
||||
"sha256": "84806fc4f8ac13dd94b380fae99330a2fbe96ece6e483c03e2411b14ddffd6e0"
|
||||
}
|
||||
],
|
||||
"dirSha256": "5106bb57dcf0fc1af391775dbb1d83850bd0fadeca32181f8c1e104c6808a7de"
|
||||
},
|
||||
"security": {
|
||||
"scannedAt": null,
|
||||
"scannerVersion": null,
|
||||
"flags": []
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user