def check(): r = urlopen(env.release_info_url).readlines()[0].split('\n')[0] if get_commit() == r: abort('ERROR: the current published version of is the same as the current commit. Make a new commit before publishing.') else: puts('[build]: the current commit is different than the published version on. Building now.')
def check(): r = urlopen(env.release_info_url).readlines()[0].split('\n')[0] if get_commit() == r: abort( 'ERROR: the current published version of is the same as the current commit. Make a new commit before publishing.' ) else: puts( '[build]: the current commit is different than the published version on. Building now.' )
def generate_meta(): m.section_break('branch/release meta', block='rel') m.var('manual-branch', docs_meta.MANUAL_BRANCH, block='rel') m.var('current-branch', str(docs_meta.get_branch()), block='rel') m.var('last-commit', str(docs_meta.get_commit()), block='rel') m.var('current-if-not-manual', str(docs_meta.get_manual_path()), block='rel') paths = docs_meta.render_paths(True) m.section_break('file system paths', block='paths') m.var('output', paths['output'], block='paths') m.var('public-output', paths['public'], block='paths') m.var('branch-output', paths['branch-output'], block='paths') m.var('rst-include', paths['includes'], block='paths') m.var('branch-source', paths['branch-source'], block='paths') m.var('public-branch-output', paths['branch-staging'], block='paths')
def main(): content = '.. |commit| replace:: ``' + get_commit() + '``' + '\n' with open('source/includes/hash.rst', 'w') as f: f.write(content)