[no-issue] Parallel run e2e and e2e common action refactoring (#4702)

This commit is contained in:
Eugenio Romano
2019-05-13 04:44:35 +02:00
committed by GitHub
parent a48bfc3714
commit 898e3b5a80
288 changed files with 8704 additions and 5130 deletions

61
scripts/release/release.sh Executable file
View File

@@ -0,0 +1,61 @@
#!/usr/bin/env bash
eval GNU=false
set -e
TEMP=".tmp";
show_help() {
echo "Usage: update-generator.sh"
echo ""
echo "-t or --token Github ouath token"
echo "-v or --version version to bump"
echo "-gnu for gnu"
}
gnu_mode() {
echo "====== GNU MODE ====="
GNU=true
}
token() {
TOKEN=$1
}
version() {
VERSION=$1
}
release() {
rm -rf $TEMP;
git clone https://$TOKEN@github.com/$1.git $TEMP
cd $TEMP
git checkout development
if $GNU; then
./scripts/update-version.sh -gnu -v $VERSION
else
./scripts/update-version.sh -v $VERSION
fi
git add .
git commit -m "Release $VERSION"
git push -u origin development
curl -H "Authorization: token $TOKEN" -X POST -d '{"body":"Release ADF version '$VERSION'","head":"'development'","base":"master","title":"Release ADF version '$VERSION'"}' https://api.github.com/repos/$1/pulls
rm -rf $TEMP;
}
while [[ $1 == -* ]]; do
case "$1" in
-h|--help|-\?) show_help; exit 0;;
-v|--version|-\?) version $2; shift 2;;
-gnu) gnu_mode; shift;;
-t|--token) token $2; shift 2;;
-*) echo "invalid option: $1" 1>&2; show_help; exit 1;;
esac
done
release 'Alfresco/alfresco-js-api'
release 'Alfresco/generator-ng2-alfresco-app'
release 'Alfresco/alfresco-ng2-components'