[projects/git-slug: 56/170] Verify that only refs/heads/ are recorded in remoterefs repo

glen glen at pld-linux.org
Mon Sep 21 21:43:31 CEST 2015


commit 1f45db90765a955dabbae12b8079f6f89d37f497
Author: Kacper Kornet <draenog at pld-linux.org>
Date:   Fri Sep 30 09:28:57 2011 +0200

    Verify that only refs/heads/ are recorded in remoterefs repo

 git_slug/refsdata.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/git_slug/refsdata.py b/git_slug/refsdata.py
index 62d376d..fd812a8 100644
--- a/git_slug/refsdata.py
+++ b/git_slug/refsdata.py
@@ -25,7 +25,8 @@ class RemoteRefsData:
     def put(self, repo, data):
         for line in data:
             (sha1_old, sha1, ref) = line.split()
-            self.heads[repo][ref] = sha1
+            if(ref.startswith('refs/heads/')):
+                self.heads[repo][ref] = sha1
 
     def dump(self, stream):
         for repo in sorted(self.heads):
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/projects/git-slug.git/commitdiff/4ed64f73960519a2f4fd04c42950b2c96ae795c5



More information about the pld-cvs-commit mailing list