git-push

git-push is a skill for Claude Code from basher83/lunar-claude. It costs 71 tokens per session (650 once invoked), scanned A, original, MIT.

A Git workflow step that publishes local commits to the shared remote repository, such as GitHub. A commit is a saved checkpoint, and a remote is the shared online copy.

In plain words
What is it for?
It is for checking the branch, integrating newer remote changes when needed, and pushing current local commits without force-pushing.
Why use it?
It prevents publishing work when the remote has newer changes or when local work has not been saved in a commit.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the blake-os plugin — 4 skills shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/basher83/lunar-claude/git-push
Any agent
npx skills add basher83/lunar-claude --skill git-push
Clone the repo
git clone --depth 1 https://github.com/basher83/lunar-claude

Made for: Claude Code.

Or install blake-os, the plugin that ships this one along with the rest of its 4 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for git-push

README.md
[![agentmods](https://agentmods.dev/badge/skills/basher83/lunar-claude/git-push.svg)](https://agentmods.dev/skills/basher83/lunar-claude/git-push)
Your own site
<a href="https://agentmods.dev/skills/basher83/lunar-claude/git-push"><img src="https://agentmods.dev/badge/skills/basher83/lunar-claude/git-push.svg" alt="Measured on agentmods" height="20"></a>
Per session 71 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 650 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00071 $0.00650
Opus 5 $0.00036 $0.00325
Sonnet 5 $0.00014 $0.00130
Haiku 4.5 $0.00007 $0.00065

Measured 2d ago against content hash 73ce8b435c38, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

git-push scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/personal/blake-os/skills/git-push/SKILL.md · 72 lines

How it starts

The opening of the file, as written. The whole thing — 72 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Git Push

Publish local commits to origin — but only when the branch is current with the remote. If the remote moved, integrate first with git-sync, then push. A push is never forced.

Prerequisites

Commit first. If the working tree has uncommitted changes, run git-commit or report what is still dirty.

Workflow

Step 1: Verify repo and remote

git remote get-url origin
git branch --show-current

If no origin remote, stop: "No remote configured. Add one with: git remote add origin "

Step 2: Fetch and measure state

git fetch origin
git rev-list --left-right --count @{u}...HEAD   # output: "<behind>	<ahead>"

The rev-list line prints behind then ahead. Decide on the numbers:

  • behind = 0, ahead = 0 — stop: "Already up to date with remote — nothing to push." (If @{u} errors because no upstream is set, the branch is new — go straight to Step 3, which sets the upstream.)
  • behind > 0 (the remote has commits the local branch doesn't, whether or not it is also ahead) — stop and do not push. Report: "Remote has N commits you don't have. Run git-sync first to integrate them (it will fast-forward or merge), then push." A push now would be rejected — do not attempt it.
  • behind = 0, ahead > 0 — clear to push. Continue to Step 3.

Step 3: Push

If the branch has no upstream:

git push -u origin HEAD

If an upstream exists:

git push

Never git push --force or --force-with-lease.

Step 4: Verify

git fetch origin && git rev-list --left-right --count @{u}...HEAD

Confirm behind = 0, ahead = 0 — local matches remote. Report: branch, remote URL, number of commits pushed.

Guardrails

  • Never force-push.
  • Never push while behind — integrate via git-sync first.
  • Never push secrets — if .env or credential files appear in the outgoing commits, stop and warn.
  • If the push is rejected for another reason (auth, pre-receive hook), report the error verbatim. Do not force.

Read the full file on GitHub · 72 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 72 lines · 71 tokens per session scan A 73ce8b435c38

Subscribe to this mod's changes

git-push is a skill published in the GitHub repository basher83/lunar-claude (22 stars, last pushed yesterday), licensed MIT. It adds 71 tokens to every session and 650 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.