# .. 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: