erinrugas

git-sync

Syncs local and remote branches safely. Use for fetch/pull/rebase/push workflows, conflict handling, and branch alignment before merge.

erinrugas 1 Updated 6mo ago
GitHub

Install

npx skillscat add erinrugas/artisan-agents/git-sync

Install via the SkillsCat registry.

About this skill

We need to produce a 2-3 sentence plain-text summary, objective, factual, no marketing, no superlatives, no calls to action. Must be at most 60 words. No quotes, no bullet points, no headings, no markdown. Just plain text. Summarize: skill syncs local and remote branches safely, handles fetch/pull/rebase/push workflows, conflict handling, branch alignment before merge. Problem: ensures branches are up-to-date, avoids conflicts, safe push. When to use: when user wants to sync with remote, branch behind base, pre-PR cleanup. Let's craft ~30 words.

SKILL.md

Git Sync Skill

When to Apply

  • User asks to sync with remote.
  • Branch is behind base branch.
  • Pre-PR branch cleanup is needed.

Workflow

  1. Fetch latest refs.
  2. Choose strategy:
    • Fast-forward pull when possible.
    • Rebase for linear history.
    • Merge when preserving branch topology is required.
  3. Resolve conflicts and re-validate locally.
  4. Push safely (--force-with-lease only after rebase when necessary).

Safety

  • Never force-push protected branches.
  • Prefer explicit base branch in commands.