[GODT-958] Release notes per each channel

This commit is contained in:
Jakub
2021-01-21 10:51:23 +01:00
committed by Jakub Cuth
parent 3168cbb77d
commit e2a30d1ac6
7 changed files with 122 additions and 19 deletions

View File

@ -19,22 +19,21 @@
# Generate HTML release notes
# hosted at https://protonmail.com/download/{ie,bridge}/release_notes.html
# hosted at https://protonmail.com/download/{ie,bridge}/{stable,early}_releases.html
INFILE=$1
OUTFILE=${INFILE//.md/.html}
# Load props
APP_TYPE=$1
if [ "$APP_TYPE" == "" ]; then
APP_TYPE="bridge"
APP_NAME="Import-Export app"
if [[ "$INFILE" =~ bridge ]]; then
APP_NAME="Bridge"
fi
APP_NAME="Bridge"
if [ "$APP_TYPE" == "ie" ]; then
APP_NAME="Import-Export app"
CHANNEL=early
if [[ "$INFILE" =~ stable ]]; then
CHANNEL=stable
fi
INFILE="release-notes/${APP_TYPE}.md"
OUTFILE="release-notes/${APP_TYPE}.html"
# Check dependencies
if ! which pandoc; then
echo "PANDOC NOT FOUND!\nPlease install pandoc in order to build release notes."
@ -42,4 +41,4 @@ if ! which pandoc; then
fi
# Build release notes
pandoc $INFILE -f markdown -t html -s -o $OUTFILE -c utils/release_notes.css --self-contained --section-divs --metadata title="Release notes - ProtonMail $APP_NAME"
pandoc $INFILE -f markdown -t html -s -o $OUTFILE -c utils/release_notes.css --self-contained --section-divs --metadata title="Release notes - ProtonMail $APP_NAME - $CHANNEL"