Repository referencing in command lines
Matthew D. Fuller
fullermd at over-yonder.net
Sat Feb 11 14:33:38 GMT 2006
On Sat, Feb 11, 2006 at 08:15:45AM -0600 I heard the voice of
John A Meinel, and lo! it spake thus:
>
> Except how do you mix working with a repository, with working without a
> repository.
>
> For example:
>
> bzr get foo.bar
>
> Are you referencing a local directory (which may not exist), or are you
> referencing the repository.
Which is why I suggest the "repo:<repo_url>:<branch_name>" syntax in
the first place 8-}
# Standalone branch at path "./foo.bar/"
% bzr get foo.bar
# Same as above; 'standalone:' marker exists for disambiguation if
# necessary
% bzr get standalone:foo.bar
# branch called 'foo.bar' in whatever repo is currently 'default',
# based on current dir or env variable or whatever
% bzr get repo::foo.bar
Now, consider these:
# branch called 'foo.bar' in repo at given URL
% bzr get repo:"sftp://me@server/some/where/my/repos":foo.bar
# Standalone branch at URL
% bzr get sftp://me@server/some/where/my/repos/foo.bar
I'm happy to have the latter syntax work just as well if that's a
branch within a repo, as if it's a standalone (that is, the latter
syntax would work in the former case, too). In fact, I'd go along
with you in saying that it almost _MUST_, for consistency and sanity.
But I want a simple and self-descriptive way to not have to talk about
where the repo is, in various cases mentioned earlier in the thread.
And since (as you say) having bzr 'guess' is a Bad Idea(tm), some
syntax has to exist to unambiguously say "I'm talking about something
in a repository, and I need to be able to unambiguously omit the URL
of the repository and talk about just the branch", which is where my
repo:/foo:bar syntax comes in.
--
Matthew Fuller (MF4839) | fullermd at over-yonder.net
Systems/Network Administrator | http://www.over-yonder.net/~fullermd/
On the Internet, nobody can hear you scream.
More information about the bazaar
mailing list