Thread (11 messages) flat view 11 messages, 7 authors, 2016-06-15

Re: [RFC/PATCH] Add multiple workdir support to branch/checkout

From: Bernhard R. Link <hidden>
Date: 2016-06-15 22:52:11

* Junio C Hamano [off-list ref] [111005 20:19]:
I do not necessarily think that it is a good approach to forbid the same
branch to be checked out in two different places, by the way. [...]
[...] The problem arises only when one of the repositories try
to update or delete the branch while it is checked out in another working
tree.
I think this is mostly the same problem that also make pushing to a
checked out branch a problem.

Isn't the real problem that a checked out branch / a branch having a
workdir only has information what branch it belongs to?

Wouldn't both problems (multiple workdirs of the same branch, pushing
to a checked out branch) solved if each working directory (including
the default one in a non-bare repository) also stored the commit id
last checked out? (And then giving a warning, error or automatically
creating a detached head setting whenever the branch it followed is
moved behind it's back?)

	Bernhard R. Link
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help