agentleFS
BigHandsDanBigHandsDan/molt/.claude/skills/commit-push-pr/SKILL.md

commit-push-pr

Skill1 starsChanged 7 months agoApache-2.0View on GitHub

Creates a git commit and pushes to remote. Use -a to amend. Optionally accepts a commit message.

  • Deletes or force-pushes
  • Commits and pushes

23 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use docs-ci, docs-interfaces and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • jh941213Skill

    docs-ci

    문서 CI(링크·OpenAPI lint·breaking 게이트·mermaid 검증)나 문서 드리프트 감지(docs.yaml 신선도 검사)를 설치하거나 돌릴 때 사용. 문서 내용 작성은 docs-architecture·docs-interfaces·docs-manuals.

    Also in 3 projects that use this

  • jh941213Skill

    docs-interfaces

    API·이벤트 인터페이스 문서(OpenAPI·swagger·AsyncAPI 명세, 엔드포인트 레퍼런스, API 구성도·시퀀스, API CHANGELOG)를 만들거나 코드와 맞출 때 사용. 시스템 구성도는 docs-architecture, API 설계 원칙은 api-design-principles.

    Also in 3 projects that use this

  • RachaelQuiselSkill

    client-docs

    Client documentation. Use when a build needs documentation updates or missing project documents need to be identified.

    Also in 3 projects that use this

  • dbankscardSkill

    techdebt

    Find and report technical debt, duplicated code, and cleanup opportunities. Run at end of sessions.

    Also in 5 projects that use this

  • planailabsSkill

    docs-architecture

    Layout, build pipeline, and structural gotchas for this dual-Astro repo. Read before changing structure, routing, or adding content. Operational/dev-server questions → dev-build skill.

    Also in 3 projects that use this

  • diego-tobalinaSkill

    build-fix

    Fix build and compilation errors systematically. Run when build fails.

    Also in 3 projects that use this

  • +4 more from jh941213

The file

Show its rules and text

We split this skill into the rules it gives an agent

17 rules. 0 are common, 10 are distinctive, and 7 are very specific to this project.

  • 0

    Common

    Most of the 17 edited versions we read keep these.

  • 10

    Distinctive

    This author's own choices. Worth a look.

  • 7

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Create a git commit with all modified code and push to the remote repository.

    line 8
  2. Distinctive:

    Run git status to see what files have changed.

    line 12
  3. Distinctive:

    Do NOT stage unrelated changes or files that shouldn't be committed (e.g., local config, debug files)

    line 15
  4. Very specific:

    Use git add <file> for specific files or git add -A if all changes should be committed

    line 16
  5. Very specific:

    If a commit message is provided, use git commit --amend -m "<message>"

    line 22
  6. Distinctive:

    If a commit message is provided, use it

    line 27
  7. Distinctive:

    If no message provided, run git diff --cached to see what's staged, then draft a concise commit message

    line 28
  8. Distinctive:

    Create a new commit with the message

    line 29
  9. Very specific:

    Check if a PR already exists for this branch: gh pr view --json url 2>/dev/null

    line 37
  10. Very specific:

    If no PR exists, create one as a draft: gh pr create --draft --title "<title>" --body "<body>"

    line 39
  11. Distinctive:

    If a PR already exists, skip this step (the push already updated it)

    line 40
  12. Very specific:

    NEVER use --force unless explicitly requested

    line 44
  13. Very specific:

    NEVER skip hooks (--no-verify) unless explicitly requested

    line 45
  14. Distinctive:

    ALWAYS create PRs as drafts — never create non-draft PRs

    line 46
  15. Distinctive:

    If the commit fails due to pre-commit hooks, fix the issues

    line 47
  16. Distinctive:

    If push fails due to remote changes, pull and rebase before retrying

    line 48
  17. Very specific:

    If push fails with 403/permission denied, fork the repo (gh repo fork --remote=true), then push to the fork and open a PR against the …

    line 49

“Common” is measured: kept by at least 6 in 10 of the 17 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Task

Create a git commit with all modified code and push to the remote repository.

Step 1: Stage Changes

Run git status to see what files have changed. Stage the relevant changes:

  • Stage files that are related to the current work
  • Do NOT stage unrelated changes or files that shouldn't be committed (e.g., local config, debug files)
  • Use git add <file> for specific files or git add -A if all changes should be committed

Step 2: Commit

If amending:

  • If a commit message is provided, use git commit --amend -m "<message>"
  • Otherwise, use git commit --amend --no-edit to keep the previous message

Otherwise:

  • If a commit message is provided, use it
  • If no message provided, run git diff --cached to see what's staged, then draft a concise commit message
  • Create a new commit with the message

Step 3: Push to Remote

Push to the remote. If amending, use git push --force-with-lease. If no upstream exists, add -u origin <branch-name>. Both flags can be combined if needed.

Step 4: Create or Update PR

Check if a PR already exists for this branch: gh pr view --json url 2>/dev/null

  • If no PR exists, create one as a draft: gh pr create --draft --title "<title>" --body "<body>"
  • If a PR already exists, skip this step (the push already updated it)

Important Notes

  • NEVER use --force unless explicitly requested
  • NEVER skip hooks (--no-verify) unless explicitly requested
  • ALWAYS create PRs as drafts — never create non-draft PRs
  • If the commit fails due to pre-commit hooks, fix the issues
  • If push fails due to remote changes, pull and rebase before retrying
  • If push fails with 403/permission denied, fork the repo (gh repo fork --remote=true), then push to the fork and open a PR against the upstream repo

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.