# Push

> Use when running git push or diagnosing why a push failed. Especially when output mixes SSH transport with hook output (lefthook, husky, pre-commit), errors include "Permission denied (publickey)" or "rejected/non-fast-forward", a pre-push hook fails, or about to debug SSH with `-v`.

- **Type:** Skill
- **Install:** `agentstack add skill-technicalpickles-pickled-claude-plugins-push`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [technicalpickles](https://agentstack.voostack.com/s/technicalpickles)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [technicalpickles](https://github.com/technicalpickles)
- **Source:** https://github.com/technicalpickles/pickled-claude-plugins/tree/main/plugins/git/skills/push

## Install

```sh
agentstack add skill-technicalpickles-pickled-claude-plugins-push
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# Git Push

Preferences for `git push`, especially diagnosing failures.

## Reading push failure output

When `git push` exits non-zero, output mixes three layers:

- SSH/transport (key offered, accepted)
- Hook driver header (lefthook, husky, pre-commit, etc.)
- Hook output (test/lint/coverage walls)

Identify the failed layer before debugging:

- `lefthook` or `hook: pre-push` → pre-push hook failed; transport was fine
- `Permission denied (publickey)` → SSH auth refused
- `! [rejected]` / `non-fast-forward` → push needs rebase

A wall of test or coverage output is NOT an SSH problem. The hook ran tests, the tests failed, the push was blocked.

## pre-push hook failures

Same rules as `pre-commit failures` in the commit skill: analyze the failures, autofix when possible, ask the user when unclear. Do NOT skip with `--no-verify` without explicit confirmation.

## Debugging SSH

Before adding `-v` to debug an SSH issue, check whether `core.sshCommand` is configured:

```
git config --get core.sshCommand
```

If it returns nothing, `GIT_SSH_COMMAND="ssh -v" git push origin ` is fine.

If it returns *anything* (custom IdentityFile, IdentityAgent, deploy-key flags, etc.), DO NOT use `GIT_SSH_COMMAND="ssh -v"`. It REPLACES `core.sshCommand` entirely, dropping every flag. Output will look like the wrong keys are being offered, because they are, but only because you removed the constraint.

Append `-v` to the existing command instead:

```
GIT_SSH_COMMAND="$(git config core.sshCommand) -v" git push origin 
```

## Background push gotcha

If you started a push with `run_in_background` and then ran a foreground retry (e.g., because the first looked stuck), the background push may have already succeeded. Before re-investigating "why is push failing":

1. `git -C  log --oneline origin/..HEAD`. Empty output means the push went through.
2. Verify retry's cwd: `pwd` and `git rev-parse --show-toplevel`.
3. `gh pr view ` to see if the commit landed.

Don't escalate to "SSH might be broken" before confirming the push didn't already complete.

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [technicalpickles](https://github.com/technicalpickles)
- **Source:** [technicalpickles/pickled-claude-plugins](https://github.com/technicalpickles/pickled-claude-plugins)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-technicalpickles-pickled-claude-plugins-push
- Seller: https://agentstack.voostack.com/s/technicalpickles
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
