hg2git: Replaces space with "_" in branches name
authorFelipe Zimmerle <felipe.zimmerle@indt.org.br>
Fri, 30 May 2008 11:41:56 +0000 (13:41 +0200)
committerRocco Rutte <pdmef@gmx.net>
Fri, 30 May 2008 11:41:56 +0000 (13:41 +0200)
Since space doesn't conform to GIT branches name standards,
it should be replaced or with another character.

Signed-off-by: Felipe Zimmerle <felipe.zimmerle@indt.org.br>
Signed-off-by: Rocco Rutte <pdmef@gmx.net>
hg2git.py

index 3015e0b..93e080f 100755 (executable)
--- a/hg2git.py
+++ b/hg2git.py
@@ -48,7 +48,7 @@ def get_branch(name):
   # HEAD may be from CVS imports into hg
   if name=='HEAD' or name=='default' or name=='':
     name=cfg_master
-  return name
+  return name.replace(' ', '_')
 
 def get_changeset(ui,repo,revision,authors={}):
   node=repo.lookup(revision)