rebase
Rebase a PR branch with the latest main branch. Features smart conflict resolution powered by AI when merge conflicts are detected.
Syntax
@Smart Workflow rebase <PR_link>Examples
@Smart Workflow rebase https://github.com/org/repo/pull/123How it works
Fetches PR branch
Gets the current state of your PR branch.
Attempts merge
Tries to merge/rebase onto latest main.
Resolves conflicts
Uses AI to resolve any conflicts semantically.
Force-pushes
Pushes the rebased branch back to the PR.
Smart Conflict Resolution
When merge conflicts are detected, Claude doesn't just pick sides—it understands the semantic intent of each change and merges them intelligently.
Analyzes both versions
Understands what each conflicting change is trying to achieve.
Semantic understanding
Goes beyond line-by-line comparison to understand code intent.
Intelligent merging
Combines changes in a way that preserves both intentions.
Safe fallback
Falls back to manual resolution if automatic resolution isn't confident.
Example Scenario
src/auth/login.ts- validateEmail(user.email)
+ validateAndNormalizeEmail(user.email)
- validateEmail(user.email)
+ validateEmail(user.email, { strict: true })+ validateAndNormalizeEmail(user.email, { strict: true })Claude understood that main renamed the function while PR added an option, and merged both changes correctly.
💡 When to use
- •Your PR is behind the main branch and needs to be updated
- •GitHub shows "This branch has conflicts that must be resolved"
- •You want a clean commit history before merging