keycloak-scim/set-version.sh

13 lines
798 B
Bash
Raw Normal View History

2018-11-14 19:16:16 +00:00
#!/bin/bash -e
VERSION=$1
SHORT_VERSION=`echo $VERSION | awk -F '.' '{ print $1"."$2 }'`
NPM_VERSION=`echo $VERSION | sed 's/.Final//' | sed 's/.CR/-cr./' | sed 's/.Beta/-beta./' | sed 's/.Alpha/-alpha./'`
mvn versions:set -DnewVersion=$VERSION -DgenerateBackupPoms=false -DgroupId=org.keycloak* -DartifactId=*
2018-11-14 19:16:16 +00:00
sed -i 's/:project_version: .*/:project_version: '$VERSION'/' topics/templates/document-attributes-community.adoc
sed -i 's/:project_versionMvn: .*/:project_versionMvn: '$VERSION'/' topics/templates/document-attributes-community.adoc
sed -i 's/:project_versionNpm: .*/:project_versionNpm: '$NPM_VERSION'/' topics/templates/document-attributes-community.adoc
sed -i 's/:project_versionDoc: .*/:project_versionDoc: '$SHORT_VERSION'/' topics/templates/document-attributes-community.adoc