Re: [PATCH] Add platform-independent .git "symlink"
- From
Brandon Casey <casey@nrlssc.navy.mil>
- Date
- Feb 4, 2008, 21:17 UTC
- Message-ID
- <47A78104.9050909@nrlssc.navy.mil>
- In-Reply-To
- <alpine.LSU.1.00.0802021825220.7372@racer.site>
Johannes Schindelin wrote:
Show 6 quoted lines
> Hi, > > BTW just to tell you why I am so excited with your patch: I have a patch > to git-branch in my tree, which implements the git-new-workdir > functionality (it's a patch to git-branch, not git-checkout, mainly > because git-checkout is no builtin yet).
Are you planning something that works like:
$ cd <my_repo>
$ git branch
* master
other_branch
$ git checkout --new-workdir ../<other_work_dir> other_branch(not sure how it would work using git-branch).
Have you thought about using git-clone instead?
It seems a good fit but would require a new option to specify a branch to checkout (which I believe is a requested feature for clone). --shared seems like a good option name*, too bad it's already taken. But how about --conjoined to communicate that the new repo and the original repo are "attached at the hip"?
$ git clone --conjoined -b other_branch <my_repo> <other_work_dir>
-brandon
* I really do think "shared" is the most appropriate since _both_ repos would be sharing, rather than the current meaning or shared which is just a short-hand for --reference and in which the original repo gets nothing from the selfish "sharer".