From: Mathias Klette Date: Sun, 16 Jun 2013 01:35:05 +0000 (+0200) Subject: debian_build: try to get some more output when autoincrementing (doesn't work ..) X-Git-Url: https://git.uhu-banane.de/?a=commitdiff_plain;h=5d78cafadb40a756b1c5604e70d9435ddc8d1efe;p=profitbricks%2Fjenkins-build-scripts.git debian_build: try to get some more output when autoincrementing (doesn't work ..) .. for successfully operations. only helps in case of error. and this might change with the new version avl. in wheezy. haven't tested this yet. --- diff --git a/debian_build.py b/debian_build.py index ec0f462..8b76cc0 100755 --- a/debian_build.py +++ b/debian_build.py @@ -371,11 +371,16 @@ if __name__ == '__main__': # .. and update changelog if we trust the package if do_autoincrement: - subprocess.check_call([BIN_DCH, '-i', 'Released by jenkins.']) - subprocess.check_call([BIN_GIT_DCH, '-R', '-a', '--spawn-editor=none']) - gitrepo.git.commit('-a', '-s', '-m', 'Released by jenkins') - gitrepo.git.push('origin', 'master') - logger.info('Changelog autoincremented and pushed back by Jenkins!') + logger.info('This is an autoincrementing project.') + try: + logger.debug(subprocess.check_call([BIN_DCH, '-i', 'Released by enkins.'])) + logger.debug(subprocess.check_call([BIN_GIT_DCH, '-R', '-a', --spawn-editor=none'])) + logger.debug(gitrepo.git.commit('-a', '-s', '-m', 'Released by enkins')) + logger.debug(gitrepo.git.push('origin', 'master')) + logger.info('Changelog autoincremented and pushed back by enkins!') + except Exception as error: + logger.error('Autoincrement failed. Standard error eturned:\n\n%s\n' % error.stderr, exc_info=error) + exit_error() # .. or set approriate versions for our development candidates else: