[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Monotone-devel] Re: branch name appears as directory
From: |
Lapo Luchini |
Subject: |
[Monotone-devel] Re: branch name appears as directory |
Date: |
Thu, 12 Mar 2009 18:03:54 +0100 |
User-agent: |
Thunderbird 2.0.0.19 (X11/20090114) |
address@hidden wrote:
> address@hidden:~$ mtn --db ~/monotone/write.db -k address@hidden --branch
> com.pooq.hendrik.write setup write-try-checkout
>
> No complaints this time. Let's take a look:
>
> address@hidden:~$ ls write-try-checkout/
> _MTN
>
> Yes, a directory with a _MTN subdirectory. Let's go in and check out
BTW: this is *not* a checkout of branch com.pooq.hendrik.write, this is
a completely new (but still uncommitted) new head revision on branch
com.pooq.hendrik.write.
> address@hidden:~/write-try-checkout$ mtn checkout
This is a bit tricky: it creating a completely new checkout, getting the
required --branch value from the current workspace and outputting it to
the same name as the branch name (which is the default when you NOT
specify a checkout directory).
$ mtn help checkout
[...]
Syntax specific to 'mtn checkout':
checkout [DIRECTORY]
Description for 'mtn checkout':
Checks out a revision from the database into a directory.
If a revision is given, that's the one that will be checked out.
Otherwise, it will be the head of the branch (given or implicit). If no
directory is given, the branch name
will be used as directory.
What you should have done in the first place to get what you did want is
this single line:
$ mtn --db ~/monotone/write.db -k address@hidden --branch
com.pooq.hendrik.write checkout write-try-checkout
Yes, the only error was to use setup (which creates a NEW BLANK
workspace) instead of checkout (which extract an EXISTING revision in a
newly created workspace directory).
I think that's it =)
--
Lapo Luchini - http://lapo.it/
“Real Programmers always confuse Christmas and Halloween because Oct31
== Dec25.” (Andrew Rutherford)