Can't create a branch

Christian Ebert blacktrash at gmx.net
Sat Oct 10 10:19:08 CDT 2009


* Adrian Buehlmann on Saturday, October 10, 2009 at 17:05:27 +0200
> On 10.10.2009 16:38, Octavian Râşniţă wrote:
>> Under Windows XP, using Mercurial Distributed SCM (version 1.3.1) 
>> I have tried to create and see a branch, but I couldn't do it.
>> 
>> Please tell me if I am doing something wrong or missing something:
>> 
>> E:\lucru\mercurial>md xxx
>> E:\lucru\mercurial>cd xxx
>> E:\lucru\mercurial\xxx>hg init
>> E:\lucru\mercurial\xxx>echo foo > file.txt
>> E:\lucru\mercurial\xxx>hg commit -A
>> adding file.txt
>> No username found, using 'Octavian at teddy' instead
> 
> See http://mercurial.selenic.com/wiki/TutorialInstall
> on the bottom for how to configure a proper username
> 
>> E:\lucru\mercurial\xxx>hg branch stable
> 
> This sets the branch name 'stable' for the next commit
> 
>> marked working directory as branch stable
> 
> as this line tells you.
> 
> See http://mercurial.selenic.com/wiki/WorkingDirectory
> and http://mercurial.selenic.com/wiki/Repository
> 
>> E:\lucru\mercurial\xxx>hg branches
>> default                        0:3a959d20bb1d
> 
> You haven't committed anything yet for the branch stable,
> So there is no such branch in the repository yet.
> The branch will not be created unless you commit something
> for it.
> 
> Change a file and commit it here.

It might be worth noting (or adding to confusion) that the file
change is not mandatory, just the commit is. In that case the
changeset just records the branch fork.

c
-- 
\black\trash movie    _C O W B O Y_  _C A N O E_  _C O M A_
                     Ein deutscher Western/A German Western

         --->> http://www.blacktrash.org/underdogma/ccc.php


More information about the Mercurial mailing list