XQUIC Safe Push
This skill owns local Git scope, commit, and push safety. It does not own pull
request body content, review state, validation semantics, or PR pre-review.
Use PR-specific skills only when those tasks are explicitly in scope.
Preflight
- Read
AGENTS.md and honor branch policy: never push directly to remote main or master.
- Check
git status --short --untracked-files=all, git branch --show-current, and git remote -v.
- Resolve the intended push remote from the user request and the repository's
current configuration:
git remote -v
git remote get-url --push <target-remote>
Remote names such as origin, upstream, or fork are local conventions,
not portable identities. Do not create, rename, or repoint a remote unless
the user explicitly requests that configuration change.
- Use an explicitly named target when the user provides one. Otherwise use
the current branch's configured upstream only when its push URL and intended
ownership are unambiguous; ask before pushing when multiple or unclear
writable targets exist.
- Show staged and unstaged scopes separately using
git diff --cached --name-status and git diff --name-status.
- If the user requested staged-only behavior, do not add any other files.
- If user-owned unrelated edits exist, leave them untouched and name them before proceeding.
- Confirm the target remote and branch before pushing.
Commit
- Commit only the intended staged files.
- Follow
CONTRIBUTING.md: commit headers use [<type>]: <subject> with
+, -, =, or ~.
- Use one concern per commit and keep debug/log-only commits out of the final
branch history.
- After commit, verify the new commit with
git log --oneline --decorate --max-count=3.
Push
Before pushing, show:
- current branch
- target remote, resolved push URL, and branch
- commits that will be pushed
- local uncommitted files that will remain local
Push when the requester explicitly asks to push or create a pull request. Also
push when the development pipeline reaches its default publication stage and
the requester has not asked to stop before publication. A missing, ambiguous,
or apparently unwritable target still requires confirmation.
Push to the resolved target without embedding repository ownership in the
skill:
git push <target-remote> <branch-name>
Forbidden
- Do not push to
origin main, origin master, or any remote main/master.
- Do not assume a remote name identifies an upstream repository, a personal
fork, or a writable target; resolve its configured push URL first.
- Do not hard-code or automatically add a contributor-owned repository URL.
- Do not use
--force unless the user explicitly requested it. Prefer --force-with-lease when force is necessary.
- Do not reset, checkout, clean, or remove files to simplify the state unless explicitly requested.
Git Conventions
Remotes
- Treat all remote names and URLs as repository-local configuration.
- Resolve the selected remote with
git remote get-url --push immediately
before pushing.
- Prefer the target named by the user. If none is named, use a configured
branch upstream only when it is clearly intended and writable.
- Keep contributor usernames, fork URLs, and machine-specific paths out of
this public skill.
Worktree Convention
Each issue uses an independent git worktree for parallel isolation:
<project-root>/ (main worktree)
<workspace-parent>/<repo>-<task-id>/ (task worktree)
Lifecycle: git worktree add -> work -> push to the resolved target -> PR
handling by the relevant PR skill -> git worktree remove.
1---2name: xquic-safe-push3description: Safely stage, commit, and push XQUIC changes after scoped Git checks. Use when asked to stage, commit, push, publish a branch to a fork, or verify that only intended files will be sent to a remote.4metadata:5 source: https://skillmd.com/skills/alibaba/xquic-safe-push6---78# XQUIC Safe Push910This skill owns local Git scope, commit, and push safety. It does not own pull11request body content, review state, validation semantics, or PR pre-review.12Use PR-specific skills only when those tasks are explicitly in scope.1314## Preflight15161. Read `AGENTS.md` and honor branch policy: never push directly to remote `main` or `master`.172. Check `git status --short --untracked-files=all`, `git branch --show-current`, and `git remote -v`.183. Resolve the intended push remote from the user request and the repository's19 current configuration:20 ```bash21 git remote -v22 git remote get-url --push <target-remote>23 ```24 Remote names such as `origin`, `upstream`, or `fork` are local conventions,25 not portable identities. Do not create, rename, or repoint a remote unless26 the user explicitly requests that configuration change.274. Use an explicitly named target when the user provides one. Otherwise use28 the current branch's configured upstream only when its push URL and intended29 ownership are unambiguous; ask before pushing when multiple or unclear30 writable targets exist.315. Show staged and unstaged scopes separately using `git diff --cached --name-status` and `git diff --name-status`.326. If the user requested staged-only behavior, do not add any other files.337. If user-owned unrelated edits exist, leave them untouched and name them before proceeding.348. Confirm the target remote and branch before pushing.3536## Commit3738- Commit only the intended staged files.39- Follow `CONTRIBUTING.md`: commit headers use `[<type>]: <subject>` with40 `+`, `-`, `=`, or `~`.41- Use one concern per commit and keep debug/log-only commits out of the final42 branch history.43- After commit, verify the new commit with `git log --oneline --decorate --max-count=3`.4445## Push4647Before pushing, show:4849- current branch50- target remote, resolved push URL, and branch51- commits that will be pushed52- local uncommitted files that will remain local5354Push when the requester explicitly asks to push or create a pull request. Also55push when the development pipeline reaches its default publication stage and56the requester has not asked to stop before publication. A missing, ambiguous,57or apparently unwritable target still requires confirmation.5859Push to the resolved target without embedding repository ownership in the60skill:6162```bash63git push <target-remote> <branch-name>64```6566## Forbidden6768- Do not push to `origin main`, `origin master`, or any remote main/master.69- Do not assume a remote name identifies an upstream repository, a personal70 fork, or a writable target; resolve its configured push URL first.71- Do not hard-code or automatically add a contributor-owned repository URL.72- Do not use `--force` unless the user explicitly requested it. Prefer `--force-with-lease` when force is necessary.73- Do not reset, checkout, clean, or remove files to simplify the state unless explicitly requested.7475## Git Conventions7677### Remotes7879- Treat all remote names and URLs as repository-local configuration.80- Resolve the selected remote with `git remote get-url --push` immediately81 before pushing.82- Prefer the target named by the user. If none is named, use a configured83 branch upstream only when it is clearly intended and writable.84- Keep contributor usernames, fork URLs, and machine-specific paths out of85 this public skill.8687### Worktree Convention8889Each issue uses an independent git worktree for parallel isolation:9091```92<project-root>/ (main worktree)93<workspace-parent>/<repo>-<task-id>/ (task worktree)94```9596Lifecycle: `git worktree add` -> work -> push to the resolved target -> PR97handling by the relevant PR skill -> `git worktree remove`.