]> Frank Brehm's Git Trees - profitbricks/jenkins-build-scripts.git/commitdiff
fix global error
authorRobin Wittler <robin.wittler@profitbricks.com>
Wed, 7 Sep 2011 09:33:00 +0000 (11:33 +0200)
committerRobin Wittler <robin.wittler@profitbricks.com>
Wed, 7 Sep 2011 09:33:00 +0000 (11:33 +0200)
build.py
lib/git_buildpackage.py

index e1f86b5fe76f2ee575b13934927d98bbf00a1298..f9ba9b8ad4b9fae3ac2f9e72b156f7a5b1840d84 100755 (executable)
--- a/build.py
+++ b/build.py
@@ -104,6 +104,7 @@ logger.setLevel(logging.DEBUG)
 def send_email(result):
     smtp = smtplib.SMTP(SMTP_SERVER)
     if result == SMTP_BUILD_ERROR:
+        global SMTP_TEXT
         SMTP_TEXT += '\nThe filesystem path is: %s' %(GIT_TARGET_WORKSPACE)
     msg = (
             'From: %s\n' %(SMTP_FROM) +
index fb874b7f142ca3a3671ffdfc7cf42b8c10d0b781..b54c6f0800a121cd6613d7fe0de3876bd2433290 100644 (file)
@@ -61,8 +61,7 @@ class GitBuildPackage(object):
 #                    '%s returned with %s. Output was: %s'
 #                    %(' '.join(cmd), ret, error_str)
 #            )
-            return False
-        return True
+        return ret
 
 
 # vim: autoindent smartindent tabstop=4 expandtab shiftwidth=4 softtabstop=4 nu enc=utf-8 cinwords=if,elif,else,for,while,try,except,finally,def,class