chore: Parse changelog in markdown into html
when publishing release.
This commit is contained in:
parent
95b1bb467e
commit
6133c6f0b5
@ -53,14 +53,14 @@ steps:
|
||||
- name: deploy-stable
|
||||
image: debian
|
||||
commands:
|
||||
- apt-get -qq update && apt-get -qq install jq curl git > /dev/null
|
||||
- apt-get -qq update && apt-get -qq install jq curl git pandoc > /dev/null
|
||||
- sed -i 's/target_version = git/target_version = stable/' configuration.default.ini
|
||||
- git fetch --tags
|
||||
- version=$(git describe --abbrev=0 --tags)
|
||||
- echo "version is $version"
|
||||
- echo $version > /mnt/botamusique/version
|
||||
- sed -i "s/version = 'git'/version = '$version'/" mumbleBot.py
|
||||
- curl --silent "https://api.github.com/repos/azlux/botamusique/releases/latest" | jq -r '.body' > /mnt/botamusique/changelog
|
||||
- curl --silent "https://api.github.com/repos/azlux/botamusique/releases/latest" | jq -r '.body' | pandoc --from gfm --to html - --output - > /mnt/botamusique/changelog
|
||||
- rm -rf .git*
|
||||
- rm -rf web
|
||||
- mkdir /tmp/botamusique
|
||||
|
@ -178,7 +178,7 @@ class MumbleBot:
|
||||
last_startup_version = var.db.get("bot", "version", fallback=None)
|
||||
if not last_startup_version or version.parse(last_startup_version) < version.parse(self.version):
|
||||
var.db.set("bot", "version", self.version)
|
||||
changelog = util.fetch_changelog().replace("\n", "<br>")
|
||||
changelog = util.fetch_changelog()
|
||||
self.send_channel_msg(constants.strings("update_successful", version=self.version, changelog=changelog))
|
||||
|
||||
# Set the CTRL+C shortcut
|
||||
|
Loading…
x
Reference in New Issue
Block a user