git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* hg2git error
@ 2009-05-24 17:33 Johannes Schindelin
  2009-05-24 17:38 ` Sverre Rabbelier
  2009-05-25 11:34 ` Rocco Rutte
  0 siblings, 2 replies; 10+ messages in thread
From: Johannes Schindelin @ 2009-05-24 17:33 UTC (permalink / raw)
  To: Rocco Rutte, Matthias Urlichs; +Cc: git

Hi,

I get this error:

Error: repository has at least one unnamed head: hg r533

How to cope with that?

Ciao,
Dscho

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: hg2git error
  2009-05-24 17:33 hg2git error Johannes Schindelin
@ 2009-05-24 17:38 ` Sverre Rabbelier
  2009-05-24 18:16   ` Johannes Schindelin
  2009-05-25 11:34 ` Rocco Rutte
  1 sibling, 1 reply; 10+ messages in thread
From: Sverre Rabbelier @ 2009-05-24 17:38 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Rocco Rutte, Matthias Urlichs, git

Heya,

On Sun, May 24, 2009 at 19:33, Johannes Schindelin
<Johannes.Schindelin@gmx.de> wrote:
> How to cope with that?

I've been working on making hg-git [0] usable as a two-way bridge
(that is, use it to interact with a hg repository using git). It is
coping just fine with unnamed heads so far :).

</shameless plug>

[0] http://hg-git.github.com/

-- 
Cheers,

Sverre Rabbelier

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: hg2git error
  2009-05-24 17:38 ` Sverre Rabbelier
@ 2009-05-24 18:16   ` Johannes Schindelin
  2009-05-24 18:20     ` Sverre Rabbelier
  0 siblings, 1 reply; 10+ messages in thread
From: Johannes Schindelin @ 2009-05-24 18:16 UTC (permalink / raw)
  To: Sverre Rabbelier; +Cc: Rocco Rutte, Matthias Urlichs, git

Hi,

On Sun, 24 May 2009, Sverre Rabbelier wrote:

> On Sun, May 24, 2009 at 19:33, Johannes Schindelin
> <Johannes.Schindelin@gmx.de> wrote:
> > How to cope with that?
> 
> I've been working on making hg-git [0] usable as a two-way bridge
> (that is, use it to interact with a hg repository using git). It is
> coping just fine with unnamed heads so far :).
> 
> </shameless plug>

It says "Achtung! Alpha!".  How alpha is it?

Also, there is the issue that it is a Hg extension.  My experience with 
such extensions and their dependency on certain Hg versions make me ask: 
what version of Hg must I install before I can use Hg-git?

Ciao,
Dscho

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: hg2git error
  2009-05-24 18:16   ` Johannes Schindelin
@ 2009-05-24 18:20     ` Sverre Rabbelier
  2009-07-22 17:47       ` Johannes Schindelin
  0 siblings, 1 reply; 10+ messages in thread
From: Sverre Rabbelier @ 2009-05-24 18:20 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Rocco Rutte, Matthias Urlichs, git

Heya,

On Sun, May 24, 2009 at 20:16, Johannes Schindelin
<Johannes.Schindelin@gmx.de> wrote:
> It says "Achtung! Alpha!".  How alpha is it?

I'm using it to work on Melange, the problems I've had with it so far
have all been fixed :).

> Also, there is the issue that it is a Hg extension.  My experience with
> such extensions and their dependency on certain Hg versions make me ask:
> what version of Hg must I install before I can use Hg-git?

Right, you will need to have hg installed to bridge between git and
hg, I think the current requirements are 'python 2.5' and 'hg 1.2' but
that's mostly because that's what we're testing, not because we depend
on specific features.

-- 
Cheers,

Sverre Rabbelier

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: hg2git error
  2009-05-24 17:33 hg2git error Johannes Schindelin
  2009-05-24 17:38 ` Sverre Rabbelier
@ 2009-05-25 11:34 ` Rocco Rutte
  2009-05-25 11:43   ` Johannes Schindelin
  1 sibling, 1 reply; 10+ messages in thread
From: Rocco Rutte @ 2009-05-25 11:34 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Matthias Urlichs, git

Hi,

* Johannes Schindelin wrote:

> Error: repository has at least one unnamed head: hg r533

I'm afraid there's nothing you can do except a) wait until somebody with
push access to the repo merges or b) do that yourself. The error means
that on a branch there's more than one head (i.e. childless
revision). There's no equivalent concept in git which is why I don't
know what to do. Generating fake branch names for git may be a little
messy I think.

Rocco

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: hg2git error
  2009-05-25 11:34 ` Rocco Rutte
@ 2009-05-25 11:43   ` Johannes Schindelin
  2009-05-25 11:57     ` Matthieu Moy
  2009-05-25 13:22     ` Rocco Rutte
  0 siblings, 2 replies; 10+ messages in thread
From: Johannes Schindelin @ 2009-05-25 11:43 UTC (permalink / raw)
  To: Rocco Rutte; +Cc: Matthias Urlichs, git

Hi,

On Mon, 25 May 2009, Rocco Rutte wrote:

> * Johannes Schindelin wrote:
> 
> > Error: repository has at least one unnamed head: hg r533
> 
> I'm afraid there's nothing you can do except a) wait until somebody with
> push access to the repo merges or b) do that yourself. The error means
> that on a branch there's more than one head (i.e. childless
> revision). There's no equivalent concept in git which is why I don't
> know what to do. Generating fake branch names for git may be a little
> messy I think.

I disagree... The worst solution is to stop working at all.  A better 
solution would be to ignore the unnamed head, and the best solution would 
probably be to generate ref names that are _not_ branch names for such 
heads.

Ciao,
Dscho

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: hg2git error
  2009-05-25 11:43   ` Johannes Schindelin
@ 2009-05-25 11:57     ` Matthieu Moy
  2009-05-25 13:22     ` Rocco Rutte
  1 sibling, 0 replies; 10+ messages in thread
From: Matthieu Moy @ 2009-05-25 11:57 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Rocco Rutte, Matthias Urlichs, git

Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:

> I disagree... The worst solution is to stop working at all.  A better 
> solution would be to ignore the unnamed head,

... or to import the commits of this unnamed head, without setting a
Git reference to it (with a message on the console saying stg like
"Unnamed head imported as commit %s\n" to let the user do something
with the sha1).

> and the best solution would probably be to generate ref names that
> are _not_ branch names for such heads.

Stg like refs/hg-heads/<branch>/<number> ? (seems to be accepted in
the Git namespace)

(my 2 cents)

-- 
Matthieu

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: hg2git error
  2009-05-25 11:43   ` Johannes Schindelin
  2009-05-25 11:57     ` Matthieu Moy
@ 2009-05-25 13:22     ` Rocco Rutte
  1 sibling, 0 replies; 10+ messages in thread
From: Rocco Rutte @ 2009-05-25 13:22 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Matthias Urlichs, git

Hi,

* Johannes Schindelin wrote:
> On Mon, 25 May 2009, Rocco Rutte wrote:
> > * Johannes Schindelin wrote:

> > > Error: repository has at least one unnamed head: hg r533

> > I'm afraid there's nothing you can do except a) wait until somebody with
> > push access to the repo merges or b) do that yourself. The error means
> > that on a branch there's more than one head (i.e. childless
> > revision). There's no equivalent concept in git which is why I don't
> > know what to do. Generating fake branch names for git may be a little
> > messy I think.

> I disagree... The worst solution is to stop working at all.  A better 
> solution would be to ignore the unnamed head, and the best solution would 
> probably be to generate ref names that are _not_ branch names for such 
> heads.

Both solutions require refactoring and new code that is abled to walk
the DAG mercurial gives us since in both cases we'd need to find the
fork point. I don't know mercurials good enough to say if and how much
its API can help here.

I don't use git any longer and do only fix obvious breakages for
hg-fast-export, read: since this is a new feature I'm afraid I won't
implement it.

Rocco

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: hg2git error
  2009-05-24 18:20     ` Sverre Rabbelier
@ 2009-07-22 17:47       ` Johannes Schindelin
  2009-07-22 18:05         ` Sverre Rabbelier
  0 siblings, 1 reply; 10+ messages in thread
From: Johannes Schindelin @ 2009-07-22 17:47 UTC (permalink / raw)
  To: Sverre Rabbelier; +Cc: Rocco Rutte, Matthias Urlichs, git

[-- Attachment #1: Type: TEXT/PLAIN, Size: 886 bytes --]

Hi,

On Sun, 24 May 2009, Sverre Rabbelier wrote:

> On Sun, May 24, 2009 at 20:16, Johannes Schindelin 
> <Johannes.Schindelin@gmx.de> wrote:
> > It says "Achtung! Alpha!".  How alpha is it?
> 
> I'm using it to work on Melange, the problems I've had with it so far 
> have all been fixed :).
> 
> > Also, there is the issue that it is a Hg extension.  My experience 
> > with such extensions and their dependency on certain Hg versions make 
> > me ask: what version of Hg must I install before I can use Hg-git?
> 
> Right, you will need to have hg installed to bridge between git and hg, 
> I think the current requirements are 'python 2.5' and 'hg 1.2' but 
> that's mostly because that's what we're testing, not because we depend 
> on specific features.

Could you give me a quick run-through how to install it and use it to 
mirror, say, the netbeans repository?

Thanks,
Dscho

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: hg2git error
  2009-07-22 17:47       ` Johannes Schindelin
@ 2009-07-22 18:05         ` Sverre Rabbelier
  0 siblings, 0 replies; 10+ messages in thread
From: Sverre Rabbelier @ 2009-07-22 18:05 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Rocco Rutte, Matthias Urlichs, git

Heya,

On Wed, Jul 22, 2009 at 17:47, Johannes
Schindelin<Johannes.Schindelin@gmx.de> wrote:
> Could you give me a quick run-through how to install it and use it to
> mirror, say, the netbeans repository?

Sure, feel free to ping me on IRC if you have any questions, I'll
explain my workflow for Melange, I reckon you can adapt it to suit
your needs.

1. clone hg-git
```
mkdir ~/code
git clone git://github.com/schacon/hg-git.git ~/code
```
2. edit your .hgrc to include the following to turn on the hg-git
plugin, and the bookmarks plugin which hg-git likes to use to store
branches from your git repository:
```
[extensions]
hgext.bookmarks =
git = ~/code/hg-git
```
3. hg clone the repository of your choice, I'll pretend it's ~/code/Melange
4. add the following to ~/code/Melange/.hg/hgrc:
```
[git]
intree=1
```
5. if possible, add '.git' to .hgignore, if not possible you'll just
have to live with it showing up in 'hg status'
6. run `hg gexport`, this will create a ~/code/Melange/.git which is a
regular git repository
7. add .hg to ~/code/Melange/.git/info/exclude
8. now each time you want to pull in new hg updates, run 'hg pull && hg gexport'
9. Depending on your preferences, you might want to add the following
to your ~/code/Melange/.hg/hgrc below intree=1:
```
exportbranch=refs/heads/from-hg
```

Doing so will cause `hg gexport` to override the 'from-hg' branch
instead of 'refs/heads/master', allowing you to work in the git
repository without worrying about losing any changes when you run `hg
gexport`.
10. Push from the git repository as usual:
```
git remote add origin ssh://srabbelier@repo.or.cz/srv/git/Melange.git
git push origin master
```

If you have any questions, feel free to ask :).

-- 
Cheers,

Sverre Rabbelier

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2009-07-22 18:05 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-24 17:33 hg2git error Johannes Schindelin
2009-05-24 17:38 ` Sverre Rabbelier
2009-05-24 18:16   ` Johannes Schindelin
2009-05-24 18:20     ` Sverre Rabbelier
2009-07-22 17:47       ` Johannes Schindelin
2009-07-22 18:05         ` Sverre Rabbelier
2009-05-25 11:34 ` Rocco Rutte
2009-05-25 11:43   ` Johannes Schindelin
2009-05-25 11:57     ` Matthieu Moy
2009-05-25 13:22     ` Rocco Rutte

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).