Skip to content

sync might not work with worktree #87

Description

@gilles

I get conflicts when syncing after a merge gh stack sync has a warning

⚠ Failed to fast-forward master: failed to run git: fatal: cannot force update the branch 'master' used by worktree at 'XXX'

seems the fix is to git rebase --onto origin/master but gh stack rebase does not have --onto

Activity

  1. self-assigned this
    on Jun 12, 2026
  2. loganrosen commented on Jul 17, 2026

    @loganrosen

    I have a tested fix available on this branch, but repository permissions prevent me from creating a PR. Could a maintainer help me get the necessary access?

  3. dgenezini commented on Jul 22, 2026

    @dgenezini

    @skarim , any updates on this? It happens with any command and is a pain when working with worktrees.

  4. added
    bugBug Reports
    topic: cli - worktreesgit worktree support: sync/rebase/checkout failures and cross-worktree stack behavior.
    and removed
    bugBug Reports
    topic: cli - worktreesgit worktree support: sync/rebase/checkout failures and cross-worktree stack behavior.
    on Jul 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugBug Reportstopic: cli - worktreesgit worktree support: sync/rebase/checkout failures and cross-worktree stack behavior.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions