Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EGit / JGit » Can one choose the location of the checked-out workspace copy?( )
Can one choose the location of the checked-out workspace copy? [message #1775974] Wed, 08 November 2017 17:47 Go to next message
Michael Moser is currently offline Michael MoserFriend
Messages: 31
Registered: October 2012
Location: Z├╝rich, Switzerland
Member
Is it possible to choose/adjust a branches checkout-location?
I would like to keep my repositories in one location and my workspace in a different one. Right now, Egit always checks out to the parent-folder of the .git folder. I would prefer to keep these directories separated, i.e.

.../some-place/foo/.git (local git repo)
.../some-other-place/workspace/* (checked out projects here)

Specifically I would like to check out projects from different repositories into the same workspace. Is that possible?

.../some-place/foo/.git (local repo1)
.../some-place/bar/.git (local repo 2)
.../some-other-place/workspace/* (projects from repo1 AND repo2 here).
Re: Can one choose the location of the checked-out workspace copy? [message #1775991 is a reply to message #1775974] Wed, 08 November 2017 23:17 Go to previous messageGo to next message
Matthias Sohn is currently offline Matthias SohnFriend
Messages: 1026
Registered: July 2009
Senior Member
You can nest working trees if their .git folders are located in the respective working tree's root folder.
And you can use submodules [1] to nest repositories.

JGit does not yet support option --separate-git-dir of the clone and init commands [2]
and it also doesn't yet support the worktree command [3].

Also native git does not support to version sibling directories/files located under the same parent
folder in different git repositories.

[1] https://rakhesh.com/coding/how-to-move-separate-the-git-folder-out-of-your-working-tree/
[2] https://git-scm.com/docs/git-worktree
Re: Can one choose the location of the checked-out workspace copy? [message #1775992 is a reply to message #1775991] Wed, 08 November 2017 23:19 Go to previous message
Matthias Sohn is currently offline Matthias SohnFriend
Messages: 1026
Registered: July 2009
Senior Member
here is [1],

[1] https://git-scm.com/docs/git-submodule
Previous Topic:Eclipse won't load .gitconfig
Next Topic:JGit support for default encoding
Goto Forum:
  


Current Time: Mon Jun 25 00:43:27 GMT 2018

Powered by FUDForum. Page generated in 0.01911 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top