[sysadmin-bin] Strip tracking branch mark in get_project_branches



commit 81150047944ca35b17cc51db8630e9be87324aa3
Author: Bartłomiej Piotrowski <bpiotrowski gnome org>
Date:   Tue Oct 29 07:54:12 2019 +0100

    Strip tracking branch mark in get_project_branches

 git/git.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/git/git.py b/git/git.py
index 8e42d1a..ddf1380 100644
--- a/git/git.py
+++ b/git/git.py
@@ -231,5 +231,5 @@ def get_project_head_name():
 
 def get_project_branches():
     lines = git.branch(list=True, _split_lines=True)
-    branches = [line.lstrip("*").lstrip() for line in lines]
+    branches = [line.split("->")[0].lstrip("*").lstrip() for line in lines]
     return branches


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]