changeset 154:5c584f0bb8aa

Merge commit 'origin/master'
author Scott Chacon <schacon@gmail.com>
date Wed, 27 May 2009 16:29:07 -0700
parents 4e7c50f8b60a (diff) 763ae6988091 (current diff)
children 4d2cc26a6e51
files
diffstat 1 files changed, 5 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/git_handler.py	Wed May 27 16:23:12 2009 -0700
+++ b/git_handler.py	Wed May 27 16:29:07 2009 -0700
@@ -192,6 +192,8 @@
 
     def export_hg_tags(self):
         for tag, sha in self.repo.tags().iteritems():
+            if tag[-3:] == '^{}':
+                continue
             if tag == 'tip':
                 continue 
             self.git.set_ref('refs/tags/' + tag, self.map_git_get(hex(sha)))
@@ -408,7 +410,6 @@
     # takes a dict of refs:shas from the server and returns what should be
     # pushed up
     def get_changed_refs(self, refs):
-        print refs
         keys = refs.keys()
 
         changed = {}
@@ -421,7 +422,9 @@
 
         tags = self.git.get_tags()
         for tag, sha in tags.iteritems():
-            changed['refs/tags/' + tag] = sha
+            tag_name = 'refs/tags/' + tag
+            if tag_name not in refs:
+                changed[tag_name] = sha
 
         for ref_name in keys:
             parts = ref_name.split('/')