Skip to content

[BUG] gtr cd Does not actually navigate to the worktree #181

Closed as not planned

Description

@claytonjroberts

Description

In the TUI (gtr cd), when trying to change my current directory to one of my worktrees, the TUI just exits with no error.

Steps to replicate:

  1. Repo directory structure should be:
    ~/some_folder/main_branch
    ~/some_folder/feature_branch
    
  2. Launch the TUI with gtr cd
  3. Use arrow keys to select the feature branch
  4. Press [enter]

System / Config

  • MacOS (M4), Tahoe 26.5
  • Fish Shell, version 4.7.1
  • git gtr version 2.7.3
  • gtr config:
    gtr.worktrees.dir                   = ~/some_folder/ [local]
    

Activity

  1. helizaga commented on Jun 9, 2026

    @helizaga
    Contributor

    Couldn't repro on 2.7.3 with your exact layout (worktrees dir as parent of main repo, tilde + trailing slash, fish) — both the picker and gtr cd <branch> navigate fine.

    Symptom matches a bug fixed in 2.7.0 (#172). git gtr version shows the binary version, not the shell function you sourced — if config.fish sources a saved copy of the init output instead of git gtr init fish | source, you'd still have the old broken function. Can you re-source fresh and retry? If it still fails: does gtr cd feature_branch (non-picker) work, and what's your fzf version? I tested on fish 4.6, so a 4.7 change isn't ruled out either.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions