# Push Skills

Push skills and global AGENTS.md to the private repo and verify the public mirror.

- Repository: https://github.com/davidondrej/skills (4238 stars)
- Category: AI and agents
- License: MIT
- Last updated: 2026-11-01
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add davidondrej/skills --skill push-skills -g -a claude-code -y`
Codex: `npx skills add davidondrej/skills --skill push-skills -g -a codex -y`
Cursor: `npx skills add davidondrej/skills --skill push-skills -g -a cursor -y`
Gemini CLI: `npx skills add davidondrej/skills --skill push-skills -g -a gemini-cli -y`

## Description

Push skills and global AGENTS.md to the private repo and verify the public mirror. Use only when the user explicitly invokes /push-skills.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Push Skills

Canonical repo: `AGENT_REPO`. Private remote: `PRIVATE_REPO`. Pushing `main` triggers the sanitized mirror at `PUBLIC_MIRROR_REPO`; only the configured automation pushes there.

Only commit or push when the user requests it. Editing this skill is not permission to publish it. For distributed skill edits, follow `distribute-skill-to-all-agents` before pushing.

## Always include global instructions

The user's standing scope for an authorized `/push-skills` run includes saved changes to `GLOBAL_INSTRUCTIONS_FILE`, unless they explicitly exclude that file. Check it on every run, even when the latest message names a skill. Preserve the conversation's original publishing objective through skill edits, renames, and other follow-up requests.

After fetching, compare saved `global/AGENTS.md` with `origin/main:global/AGENTS.md`. Local dirt may already be published; Git status alone cannot tell. Transfer new edits while preserving upstream changes.

Verify saved global instructions are committed privately and substantive updates appear in public root `AGENTS.md`. Report this separately; successful skill publication does not complete an AGENTS.md request.

## Choose the source file

- `GLOBAL_INSTRUCTIONS_FILE` should link to `AGENT_REPO/global/AGENTS.md`. Save the editor buffer and verify the link. If it differs, inspect both files before choosing; do not replace the link or overwrite either file. Public destination: root `AGENTS.md`.
- `AGENT_REPO/AGENTS.md` is a separate, private repo-instruction file and stays excluded.
- Updating global instructions needs no copy, skill allowlisting, or policy version bump.
- Skills live under `skills/<skill-name>/`. Use `publish-skill` for newly public skills; include policy changes in the same commit.

## Prepare without disturbing other work

Run Git in `AGENT_REPO` or the temporary worktree below. Check staged and unstaged changes:

The rest: https://github.com/davidondrej/skills/blob/HEAD/skills/skill-authoring/push-skills/SKILL.md
