Background tasks don't sync changes to working directory when completed
Resolved 💬 3 comments Opened Jan 25, 2026 by erace Closed Jan 29, 2026
Description
When running tasks in the background via Claude Code CLI, if the task makes changes, commits them to a feature branch, and pushes to remote, the local working directory doesn't automatically receive those changes when the task completes or when resuming.
Current Behavior
- User starts a background task
- Task makes file changes
- Task commits to a feature branch and pushes to remote
- Task completes
- User resumes/checks results but local working directory doesn't have the new files
- User must manually pull/merge to get the changes
Expected Behavior
When a background task completes, the changes should be available in the local working directory without requiring manual git operations. Options could include:
- Automatically merge the feature branch back to the working branch
- Keep changes staged/committed on the current branch instead of a separate feature branch
- Provide a prompt to sync changes when task completes
- Auto-pull when resuming a completed background task
Impact
This creates a confusing workflow where:
- The task reports success
- Files appear to be created (in the task output)
- But the user can't see or use the files until manual git operations
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗