ci(common): Support for tagging and releasing in CI

This commit is contained in:
David Cermak
2023-04-19 15:39:35 +02:00
parent 6c299c068b
commit 6daf6c6ba6
5 changed files with 92 additions and 8 deletions

View File

@ -93,6 +93,13 @@ def main():
updated_changelog.write(orig_items)
git.add(filename)
# write the current changelog entry to a local text file (removing links, captions and extra newlines)
changelog = re.sub(r'\[([^\]]+)\]\([^\)]+\)', r'\1', changelog)
changelog = re.sub(r'\#\#[\#\s]*(.+)', r'\1', changelog)
changelog = re.sub(r'\n\n', '\n', changelog)
with open(os.path.join(root_path, 'release_notes.txt'), 'w') as release_notes:
release_notes.write(changelog)
if __name__ == '__main__':
main()