wt-sync
Sync current git worktree with upstream remote changes. Use when pulling latest changes from the remote branch. Handles uncommitted changes with stashing, offers rebase or merge.
When & Why to Use This Skill
The wt-sync Claude skill streamlines Git version control workflows by automating the synchronization of local worktrees with upstream remote changes. It enhances developer productivity by handling complex Git operations like stashing uncommitted changes, fetching updates, and managing rebase or merge strategies through a simplified interface.
Use Cases
- Team Collaboration: Quickly update your local environment with the latest changes pushed by teammates to the remote repository to avoid drift.
- Safe Context Switching: Synchronize your branch even with uncommitted work by leveraging the automatic stash and restore functionality to prevent data loss.
- Workflow Standardization: Maintain a clean project history by easily choosing between rebase or merge strategies during the synchronization process.
- Efficiency Optimization: Reduce manual Git command overhead by executing a multi-step fetch and sync workflow with a single slash command.
| name | wt-sync |
|---|---|
| description | Sync current git worktree with upstream remote changes. Use when pulling latest changes from the remote branch. Handles uncommitted changes with stashing, offers rebase or merge. |
/wt:sync - Sync Worktree with Upstream
Description
Quick command to sync the current worktree with upstream changes from the remote repository.
Usage
/wt:sync
What It Does
This slash command:
- Activates the Git Worktree Manager skill (
@git-worktree) - Automatically runs the
*synccommand - Syncs your worktree with the remote branch
Workflow
The command will:
- Check working directory - Verify it's clean (or offer to stash)
- Fetch from origin - Get latest remote changes
- Ask merge preference - Rebase or merge?
- Sync the branch - Apply the chosen strategy
- Show results - Display what changed
Benefits
✅ Stay Updated - Keep worktree in sync with remote ✅ Safe Process - Handles uncommitted changes ✅ Flexible - Choose rebase or merge ✅ Automatic Stash - Stashes and restores changes
Notes
- If you have uncommitted changes, they'll be stashed and restored
- You can choose between rebase (cleaner) or merge (safer)
- The command will show you what changed after syncing