← Back to list

git-push-helper
by zichenggu72
⭐ 1🍴 0📅 Jan 13, 2026
SKILL.md
name: git-push-helper description: Check git status, review changes, and push commits to remote repository. Use when the user wants to check what changes are staged/unstaged, see git status, review commits, or push to origin. Helps with git workflows like checking status before pushing or handling uncommitted changes. allowed-tools: Bash(git:*)
Git Push Helper
This skill helps you safely check your git status and push changes to your remote repository.
Instructions
When the user asks to push commits, check git status, or review changes:
- Check current status: Run
git statusto show what's staged, unstaged, or untracked - Show branch info: Run
git branch -vvto show current branch and tracking info - Show recent commits: Run
git log --oneline -5to show recent commits - Check what will be pushed: Run
git log origin/HEAD..HEAD --onelineto see unpushed commits - Verify before pushing: Always show the status and let the user confirm
- Push safely: Use
git push origin HEADto push current branch - Confirm success: Show the push result and verify with
git status
Important safeguards
- Always run
git statusbefore pushing - Show the user what commits will be pushed
- Never force push (avoid
git push -forgit push --force) - If there are conflicts, explain them clearly and help resolve
- If the branch has no remote tracking, ask which remote to use
- Check for uncommitted changes and warn the user
Common workflows
Push current changes
# 1. Check status
git status
# 2. Show what will be pushed
git log origin/$(git rev-parse --abbrev-ref HEAD)..HEAD --oneline
# 3. Push to origin
git push origin HEAD
Check status only
# 1. Show status
git status
# 2. Show branch info
git branch -vv
# 3. Show recent commits
git log --oneline -5
Review before push
# 1. Check status
git status
# 2. Show diff of staged changes
git diff --staged
# 3. Show commits that will be pushed
git log origin/$(git rev-parse --abbrev-ref HEAD)..HEAD --oneline
# 4. Push if user confirms
git push origin HEAD
Examples
Example 1: User says "push my changes"
Response:
- Run:
git status - Run:
git log origin/main..HEAD --oneline(or current branch) - Show output: "You have X commits ready to push: [list commits]"
- Ask: "Ready to push these changes to origin?"
- If yes: Run
git push origin HEAD - Show confirmation: "Successfully pushed to origin/[branch]"
Example 2: User says "check git status"
Response:
- Run:
git status - Run:
git branch -vv - Run:
git log --oneline -5 - Explain: "You're on branch X. You have Y commits ahead of origin."
Example 3: User says "what's ready to push?"
Response:
- Run:
git status - Run:
git log origin/HEAD..HEAD --oneline - If there are unpushed commits, list them
- If there are uncommitted changes, warn about them
- Ask if they want to push
Error handling
If push fails:
- Check
git statusto see if there are conflicts - Run
git pull --rebaseif remote has newer commits - Explain the issue clearly to the user
- Never automatically force push
If there's no remote tracking branch:
- Run
git branch -vvto check - Ask user which remote to push to
- Suggest:
git push -u origin [branch-name]
Score
Total Score
50/100
Based on repository quality metrics
✓SKILL.md
SKILL.mdファイルが含まれている
+20
○LICENSE
ライセンスが設定されている
0/10
○説明文
100文字以上の説明がある
0/10
○人気
GitHub Stars 100以上
0/15
○最近の活動
3ヶ月以内に更新がある
0/10
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
○タグ
1つ以上のタグが設定されている
0/5
Reviews
💬
Reviews coming soon