[projects/git-slug: 135/170] Avoid harcoding of "origin" in showfile

glen glen at pld-linux.org
Mon Sep 21 21:50:09 CEST 2015


commit e215bafc7b732414ede101f1938198b5e0375e28
Author: Kacper Kornet <draenog at pld-linux.org>
Date:   Thu Jul 5 15:40:37 2012 +0100

    Avoid harcoding of "origin" in showfile

 git_slug/gitrepo.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/git_slug/gitrepo.py b/git_slug/gitrepo.py
index 91bcccd..27ba357 100644
--- a/git_slug/gitrepo.py
+++ b/git_slug/gitrepo.py
@@ -87,6 +87,6 @@ class GitRepo:
             localref = EMPTYSHA1
         return localref
 
-    def showfile(self, filename, ref='origin/master'):
+    def showfile(self, filename, ref="/".join([REMOTE_NAME, "master"])):
         clist = ['show', ref + ':' + filename]
         return self.command(clist)
================================================================

---- gitweb:

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



More information about the pld-cvs-commit mailing list