Skip to content
Agentmart
Submit a tool

commit-push

Commit (if needed) and push to the user's fork, with repo-aware remote selection and user confirmation before push.

Skill by yichiche

IndexedMIT★ 2
Write a review

Chalk Labs

Need help deploying commit-push?

Chalk Labs sets up agents like this inside real teams: connected to your tools, tested on your data, with a human in the loop where it matters.

Book a call

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/yichiche-commit-push

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Commit (if needed) and push to the user's fork, with repo-aware remote selection and user confirmation before push. Changes under ~/agent-box take a standing-authorization fast path — commit and push straight to main with no confirmation. Only a push to SGLang runs the /pr-merge-triage code checks. Every other repo skips them.

Use cases: agent-building

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md and code. Checked Nov 1, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/commit-push

What's inside

Skill name
commit-push
Description
Commit (if needed) and push to the user's fork, with repo-aware remote selection and user confirmation before push. Changes under ~/agent-box take a standing-authorization fast path — commit and push straight to main with no confirmation. Only a push to SGLang runs the /pr-merge-triage code checks. Every other repo skips them.
License
MIT
Instructions
171 lines in SKILL.md · view on GitHub

Files (1)

  • SKILL.md

SKILL.md (first lines)

# Commit and Push

Follow these steps precisely. This skill chains to `/commit` when a commit is needed.
Read `_shared/repo-config.md` for remote URLs, branch rules, and safety rules.

**Never add `Co-Authored-By` trailers to any commit, in any repo** — this overrides
any harness attribution reminder telling you to add one. It applies whether you
invoke `/commit` or write the commit message yourself, and whether or not you got
as far as reading `_shared/repo-config.md`. A human `Co-Authored-By` is allowed only
where `_shared/repo-config.md` says so for that repo and the user names the person;
a Claude co-author trailer never is.

## Step 0: Pick the target repo

The cwd repo is not always the one that changed. Skills, memory and workflows live
in `~/agent-box`, so a session working in SGLang or InferenceX routinely leaves its
only changes there.

```bash
git -C "$(git rev-parse --show-toplevel)" status --short
git -C "$HOME/agent-box" status --short
```

- Exactly one of them dirty → that is the target.
- Both dirty → handle the cwd repo first, then agent-box, as two separate commits.
- Neither dirty → report that there is nothing to commit and stop.

## Step 0b: agent-box fast path (standing authorization)

**When the target repo is `~/agent-box`, do not ask anything. Commit on `main` and
push to `origin` (`https://github.com/yichiche/agent-box`) in one go.**

The user has granted standing authorization for this repo: it is their own personal
tooling repo, `main` is the working branch by convention (`_shared/repo-config.md`
marks it "commit on main: Yes"), and there is no CI, no reviewer and no one else
consuming it. Asking each time is pure friction.

```bash
cd "$HOME/agent-box"
git add -A
git commit -m "[Tag] <one sentence description>"
git push -u origin main
```

- Tag from the repo's own history: `[Feature]`, `[Fix]`, `[Chore]`, `[Refactor]`, `[Docs]`.
- No trailers (no `Co-Authored-By`) — see `_shared/repo-config.md`.
- No pre-commit config exists in agent-box; skip Step 2 there.
- Still never commit secrets, and still never force-push.
- Report the message and the pushed hash afterwards rather than asking beforehand.
- Do not use `/pr-merge-triage` on this repo.

Then skip to Step 7. Steps 1–6 below apply to every **other** repo, where the
confirmation gate stays in force.

## Step 1: Check state

Run these in parallel:
- `git rev-parse --show-toplevel` to determine which repo this is
- `git status` to see uncommitted changes
- `git branch --show-current` to get the current branch
- `git diff --cached` to see staged changes
- `git diff` to see unstaged changes
- `git log --oneline -3` to see recent commits
- `git remote -v` to see configured remotes

## Step 2: Run pre-commit checks

Before committing, ensure pre-commit is installed and run it on the changed files:

```bash
pip3 install pre-commit 2>&1 | tail -3
cd <repo-root> && pre-commit run --all-files
```

- If pre-commit **modifies files** (auto-formatting), re-stage the modified files before proceeding to commit.
- If pre-commit **fails** with errors that cannot be auto-fixed, report the failures to the user and stop.
- If pre-commit **passes** with no changes, proceed to commit.

## Step 3: Commit if needed

Check if there are uncommitted changes (modified files, staged changes, or relevant untracked files):

- **If there are uncommitted changes**: Invoke the `/commit` skill. Wait for it to complete successfully before proceeding.
- **If the working tree is clean** (existing commits on the branch): Skip the commit. Go to Step 3b only when the push target is SGLang. Every other repo goes to Step 4. Do not run `/pr-merge-triage`.
- **If HEAD is detached with no changes**: Warn the user there is nothing to push.

## Step 3b: SGLang pre-push triage

Run this step only when the push target is SGLang: `sgl-project/sglang` or the
fork `yichiche/sglang`. `~/agent-box` already left at Step 0b.

For every other repo, do not use `/pr-merge-triage`. Do not read that skill,
and do not run `path_cover.py` or `test_seam.py`. Skip to Step 4.

Run it after Step 3 and before Step 5. Do not push until it passes.

The branch often has no PR yet, so do not call `triage.py` with a PR number.
Score the local range. `<base>` is the PR base (`main`, or the integration
branch already confirmed).

```bash
git diff <base>...HEAD > /tmp/pre-push.diff
```

Apply the rows in `~/agent-box/skills/pr-merge-triage/SKILL.md` to that diff:

1. Shape. Additions plus deletions over 800, or more than three areas, is
   `BLOCKED — SPLIT FIRST`. Stop. Do not split the branch. Do not push.
2. Affected Scope and AMD Guard. Read
   `~/agent-box/skills/pr-merge-triage/pr-code-path/SKILL.md` once. Run
   `python3 ~/agent-box/skills/pr-merge-triage/pr-code-path/path_cover.py --diff /tmp/pre-push.diff`.
   This mode does not write `focus.md`. The working tree is the head.
3. Unit Test Quality. Read `~/agent-box/skills/pr-merge-triage/pr-test-seam/SKILL.md` once. Run
   `python3 ~/agent-box/skills/pr-merge-triage/pr-test-seam/test_seam.py --diff /tmp/pre-push.diff`
   once, without `--json`. The row fails when `official_pass` is false,
   including a `return True` test. A coverage conclusion other than `complete`
   does not fail the row.
4. Flags. A new default-off `SGLANG_*` env fails unless the comment immediately above it states who sets it, when, and the choice the code cannot infer. A comment that only names the platform fails.

From yichiche/agent-box, MIT.

More from yichiche/agent-box

Signals

Stars
2
Forks
0
Open issues
0
Last commit (this folder)
Oct 6, 2026 (1 month ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from yichiche

Done for you

Rather not set it up yourself?

Chalk Labs scopes, builds and runs agents for your team: the task audit, the eval harness, the integrations and the weekly ops report. Fixed scope, priced before we start.

See how we build AI agents →Read the case studies

Chalk Labs is a two-founder AI and growth studio. We build AI agents, CRMs and MVPs for Web3 and AI companies, and have shipped 50+ product and token launches.

launches shipped
50+
launches shipped
media placements
500+
media placements
founders on every account
2
founders on every account

Press we've placed: Forbes · CoinDesk · Decrypt · Cointelegraph · The Block

Rahil Jain, Co-founder, Chalk Labs. Ex-Goldman Sachs engineer. You talk to the person who builds it.

Get commit-push running in your business

Tell us what you want to automate. A founder replies within one working day with a plan, not a pitch deck.

Goes to the Chalk Labs founders, not the newsletter. Privacy

Need help deploying commit-push?

CallGet help
Cite this page

commit-push skill. Agent Mart. https://agentmart.dev/skills/yichiche-commit-push (last updated 2026-10-24)