-
Notifications
You must be signed in to change notification settings - Fork 56
/
tag-beta.bash
31 lines (30 loc) · 1.31 KB
/
tag-beta.bash
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
if [[ $GITHUB_REF != refs/tags/* ]]; then
if [[ "$GITHUB_REF" != "refs/heads/develop" ]]; then
echo "Skipping tag for $GITHUB_REF ref."
export SKIP=1
else
VERSION=$(/usr/libexec/PlistBuddy -c "print :CFBundleShortVersionString" "build/Release/MetaZ.app/Contents/Info.plist")
git config --global user.email "builds@metaz.maven-group.org"
git config --global user.name "CI"
export GIT_TAG=v${VERSION}
echo git tag $GIT_TAG -a -m "Generated tag from CI for build $GITHUB_RUN_NUMBER"
git tag $GIT_TAG -a -m "Generated tag from CI for build $GITHUB_RUN_NUMBER"
git push -q https://$GITHUB_TOKEN@github.com/griff/metaz --tags
#export RELEASE_NAME="$(echo "$VERSION" | sed -e 's/.beta-/ Beta /')"
fi
else
echo "Build is a tag"
VERSION=$(/usr/libexec/PlistBuddy -c "print :CFBundleShortVersionString" "build/Release/MetaZ.app/Contents/Info.plist")
#export RELEASE_NAME="$(echo "$VERSION" | sed -e 's/.beta-/ Beta /')"
#export GIT_TAG="$TRAVIS_TAG"
git fetch --tags
fi
#if [ -z "$SKIP" ]; then
# Scripts/release-notes.rb
# Scripts/release-notes.rb > build/Release/Release-notes.md
# bundle exec Scripts/github_release.rb \
# --secret "$GITHUB_TOKEN" \
# --repo-slug griff/metaz \
# --changelog-file build/Release/Release-notes.md \
# --tag $GIT_TAG
#fi