On 20/10/06, Jakub Narebski <jnareb@gmail.com> wrote:
My understanding of git is that this would be equivalent to the "bzr
branch" command. A checkout (heavy or lightweight) has the property
that commits are made to the original branch.
I suppose that'd be useful if you want a copy of all the branches at
once. There is no builtin command in Bazaar to do that at present.
I guess this highlights that the two tools optimise for different workflows.
Two points:
(1) if we are publishing branches, we wouldn't include working trees
-- they are not needed to pull or merge from such a branch.
(2) if we did have working trees, they'd be rooted at /repo/branch1
and /repo/branch2 -- not at /repo (since /repo is not a branch).
In case (2) there is a potential for conflicts if you nest branches,
but people don't generally trigger this problem with the way they use
Bazaar.
That is fairly similar to the default mode of operation with Bazaar:
you have a repository, branch and working tree all rooted in the same
directory. If you have separated working trees and branches, then
that is because you specifically asked for it.
I think you have a slight misunderstanding of what a Bazaar checkout is.
The layout of a standalone branch would be:
.bzr/repository/ -- storage of trees and metadata
.bzr/branch/ -- branch metadagta (e.g. pointer to the head revision)
.bzr/checkout/ -- working tree book-keeping files
source code
If we use a shared repository, the contained branches would lack the
.bzr/repository/ directory. The parent directory would instead have a
.bzr/repository/, but usually wouldn't have .bzr/branch/ (unless there
is a branch rooted at the base of the repository).
if we are publishing a branch to a web server, we'd skip the working
tree, so the source code and .bzr/checkout/ directory would be
missing.
In the case of a checkout, the .bzr/branch/ directory has a special
format and acts as a pointer to the original branch. If the checkout
is lightweight, the .bzr/repository/ directory would be missing, and
bzr would need to contact the original branch for the data.
Okay. So using Bazaar terminology, this seems to be an issue of the
working tree being associated with the repository rather than the
branch?
[...]
Well, a branch can easily have multiple URLs even if there is only one
copy of it. I might write to it via local file access or sftp (which
would be a file: or sftp: URL).
Mirrors of branches don't usually confuse users (and remember that the
revision numbers are primarily intended for users -- if I am writing a
Bazaar plugin, I'd work in terms of revision IDs).
James.
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html