skills/git-workflows/skills/sync/SKILL.md
Use when fetching and reviewing remote changes without modifying the local branch state.
npx skillsauth add dtsong/my-claude-setup git-syncInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
git fetch --prune which updates remote tracking refs and removes stale ones.., shell metacharacters, or null bytes.--all accepted. Reject arbitrary strings.Fetch the latest changes from remote without modifying your local branch. Shows what's new upstream.
/git-sync # Fetch all remotes and show status
/git-sync origin # Fetch specific remote
/git-sync --all # Fetch all remotes including tags
# Fetch from all remotes with prune
git fetch --all --prune
# Get current branch
git branch --show-current
# Check remote tracking status
git status -sb
# Get the remote tracking branch
REMOTE_BRANCH=$(git rev-parse --abbrev-ref --symbolic-full-name @{u} 2>/dev/null)
# If tracking branch exists, show difference
if [ -n "$REMOTE_BRANCH" ]; then
# Commits behind (on remote but not local)
git log --oneline HEAD..$REMOTE_BRANCH
# Commits ahead (on local but not remote)
git log --oneline $REMOTE_BRANCH..HEAD
fi
# Files that would change on pull
git diff --stat HEAD..@{u} 2>/dev/null
Fetched from origin, upstream
Current branch: feat/dark-mode
Tracking: origin/feat/dark-mode
Behind by 3 commits:
abc1234 Fix theme persistence
def5678 Update color palette
ghi9012 Add system theme detection
Ahead by 1 commit:
xyz7890 WIP: toggle component
Files that would change on pull:
src/theme/colors.ts | 12 ++++++------
src/hooks/useTheme.ts | 45 +++++++++++++++++++++++++++++++++++++++++++++
Next steps:
/git-pull # Pull the changes
/git-stash # Stash local changes first
Branch 'feat/local-only' has no upstream tracking branch.
To set tracking:
git branch --set-upstream-to=origin/feat/local-only
Or push with tracking:
git push -u origin feat/local-only
Current branch: main
Tracking: origin/main
Already up to date.
Failed to fetch from origin: Could not resolve host: github.com
Check your network connection and try again.
/git-pull to apply the fetched changes/git-stash if you have uncommitted changes to save first/git-branches to see status of all branchesdevelopment
Use when the council needs to surface organizational knowledge buried across multiple internal sources (wikis, design docs, ADRs, past tickets, postmortems, chat archives, code repos). Plans where to look, what to cross-reference, and how to synthesize findings into evidence the council can act on. Do not use for external market research (use competitive-analysis), library evaluation (use library-evaluation), or technology trend assessment (use technology-radar).
testing
Use to convert a Word .docx file to PDF and/or verify its page count. Triggers on: converting docx to pdf, rendering a document, checking how many pages a docx produces, or asserting a page-count constraint (e.g. a resume must stay 2 pages). Wraps LibreOffice headless conversion.
development
Security audit checklist for web applications. Use when reviewing, auditing, or hardening a web app's security posture. Covers rate limiting, auth headers, IP blocking, CORS, security middleware, input validation, file upload limits, ORM usage, and password hashing. Triggers on requests like "review security", "harden this app", "security audit", "check for vulnerabilities", or when building/reviewing API endpoints.
development
Interactive wizard to craft effective prompts using Claude Code best practices