remove extra 'v' in version string for cron compare (#1812)

This commit is contained in:
Gary Verhaegen 2019-06-21 18:34:19 +01:00 committed by GitHub
parent ceceabcc6a
commit e6ee95c544
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -30,6 +30,8 @@ jobs:
- bash: |
set -euo pipefail
LOG=$(Build.StagingDirectory)/log.txt
touch $LOG
CUR_SHA=$(git rev-parse HEAD)
robustly_download_nix_pkgs() {
@ -58,7 +60,7 @@ jobs:
GH_VERSIONS=$(mktemp)
DOCS_VERSIONS=$(mktemp)
curl -s https://docs.daml.com/versions.json | jq -r 'keys | .[]' | sort > $DOCS_VERSIONS
echo $RELEASES | sed 's/ /\n/g' | sort > $GH_VERSIONS
echo $RELEASES | sed 's/ /\n/g' | sed 's/^v//' | sort > $GH_VERSIONS
if diff $DOCS_VERSIONS $GH_VERSIONS; then
echo "No new version found, skipping."
exit 0
@ -67,7 +69,6 @@ jobs:
echo "Building docs listing"
DOCDIR=$(Build.StagingDirectory)/docs
mkdir -p $DOCDIR
LOG=$(Build.StagingDirectory)/log.txt
LATEST=$(echo $RELEASES | awk '{print $1}')
JSON_BODY=$(echo $RELEASES | sed -e 's/ /\n/g' | sed -e 's/v\(.*\)/"\1": "\1",'/g)
echo "Building latest docs: $LATEST"