Support Worktrees 🌲
A Git worktree is a linked copy of your Git repository, allowing you to have multiple branches checked out at a time. A worktree has a separate path from your main working copy, but it can be in a different state and on a different branch.
Git SCM reference link: https://git-scm.com/docs/git-worktree
As a user, I want GitKraken to support worktrees.
Comments: 18
-
15 Jun, '21
Gabriel LascanoThis would be a great addition I support it 100%.
-
16 Jun, '21
Elliot DerhayThis sounds nice to have to me, although I admit I probably wouldn't use it that often.
I'm curious about how it would be implemented. Would the tree indicate that there are 2 heads checked out, and consequently 2 sets of WIP changes? How would GK know which tree to use for adding commits? -
25 Jun, '21
Max MoldmannMost functionality is already there. GitKraken has learned a while ago to load worktree's as a separate repository.
GitKraken will also tell you if you are trying to checkout a branch that is already used by a linked repository.
GitKraken just does not list worktree repo's in the Project directory repo lists, you have to manually open them via the "Open repository" dialog. -
15 Jul, '21
JonathanThe way I'd want to see it is that where you would normally switch branch, that would just show you the context of that worktree (or add a dropdown next to the branch checkout for worktrees)
See image here: https://ibb.co/t3b8MBg -
26 Jul, '21
krurschakWould be great to have this Git native feature in the UI :)
-
10 Aug, '21
Alexis LucattiniThis is also needed in order to have 'sparse-configs'
-
03 Sep, '21
KevinWorktree project won't be list in "Recently Opened" or "Favorites", need manually open it every time.
When switch from other tab to worktree project tab, all previous loaded data and UI are gone, and it show a loading dialog to open repo, it's very annoying.
This bad support of worktree prevent me switching from Souretree which can treat worktree project as normal project, nearly perfect. -
21 Sep, '22
PeterWORKTREES is one the most useful features when you have to manage a team of developers and you have to help them out while they are working on different branches.
Seeing that Kraken doesn't completely support it yet - was almost a deal breaker for me -
21 Sep, '22
Joey Kelroy Admin"Support for worktrees in Project directories" (suggested by Harry Phillips on 2022-09-13), including upvotes (1) and comments (0), was merged into this suggestion.
-
31 Oct, '22
Chris Abernethy+1, Worktree support would be very useful
-
10 Jan
Mike Worthington+1, GitLens already has support. Would be great if GitKraken Client also supported worktrees. It's a bit jarring when I double click on a branch and I get an error that tells me I already have it checked out.
-
13 Jan
Jeremiah SneeAlso would be nice to have a open worktree in VSCode UI option. and as well as open GitKraken from GitLens in VSCode.
-
10 Mar
JoelI'd love to see this. Worktrees are getting more popular. They are very useful. Sourcetree has them.
-
14 Mar
IsaacBThere has historically been a complete absence of support for the not really related core.worktree setting for the main working tree to reside in a different place from the repository files in ALL git GUIs using libgit2 in any capacity. Literally, the only one that supports core.worktree to this day is GitExtensions. I would imagine whatever prevents them from supporting the simple 18 year old git feature of having your main worktree not be in the same place as the git repository folder is also an issue for the additional worktrees.
I'm excited at the prospect that GitKraken might add support for additional worktrees (as simple as creating tabbed history display for "Main" and each branch that has an additional worktree) since I make heavy use of this feature in order to compare proprietary binary files in their editor without setting up external diff and merge tools for everything. I'm also hoping that this may cause them to fix support for the core.worktree setting also. -
06 Jun
SulemanThis is a really useful feature. Any timeline when this will be implemented?
-
03 Nov
Declan BrownWould really appreciate this feature
-
08 Nov
Ryan Craig MartinSupport to match or improve upon GitLens would be amazing.
-
17 Nov
romibiI use worktrees to save harddrive space as I have multiple branches of the same big repository checked out at the same time.
Up until GitKraken 9.10 working with worktree checkouts worked fine even with enabled Experimental Feature "Use Git Executable".
Now I need to disable that to be able to pull (and probably more)
I assume until GitKraken 9.9.2 for pull the internal library was used even with that feature enabled, as i was unable to detect a git.exe call.
Now with GitKraken 9.10 the git.exe pull call is run with the "Current Directory" of "…\.git\worktrees\name\" instead of the opened repo folder.
Without "Use Git Executable" everything works fine.
Although a worktree UI would be nice. My main concern is beeing able to use an existing worktree.