Skip to content

Commit

Permalink
chore: updated conditions in automatic release scripts (#332)
Browse files Browse the repository at this point in the history
  • Loading branch information
adityastic authored and iamareebjamal committed May 26, 2019
1 parent a5719b1 commit 39bba2f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion scripts/prep-key.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ set -e

export DEPLOY_BRANCH=${DEPLOY_BRANCH:-master}

if [[ "$TRAVIS_PULL_REQUEST" != "false" -o "$TRAVIS_REPO_SLUG" != "fossasia/badge-magic-android" -o "$TRAVIS_BRANCH" != "$DEPLOY_BRANCH" ]]; then
if [ "$TRAVIS_PULL_REQUEST" != "false" -o "$TRAVIS_REPO_SLUG" != "fossasia/badge-magic-android" -o "$TRAVIS_BRANCH" != "$DEPLOY_BRANCH" ]; then
echo "We decrypt key only for pushes to the master branch and not PRs. So, skip."
exit 0
fi
Expand Down
2 changes: 1 addition & 1 deletion scripts/upload-apk.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ git config --global user.email "noreply+travis@fossasia.org"
export DEPLOY_BRANCH=${DEPLOY_BRANCH:-development}
export PUBLISH_BRANCH=${PUBLISH_BRANCH:-master}

if [[ "$TRAVIS_PULL_REQUEST" != "false" || "$TRAVIS_REPO_SLUG" != "fossasia/badge-magic-android" ]] || ! [[ "$TRAVIS_BRANCH" == "$DEPLOY_BRANCH" || "$TRAVIS_BRANCH" == "$PUBLISH_BRANCH" ]]; then
if [ "$TRAVIS_PULL_REQUEST" != "false" -o "$TRAVIS_REPO_SLUG" != "fossasia/badge-magic-android" ] || ! [ "$TRAVIS_BRANCH" == "$DEPLOY_BRANCH" -o "$TRAVIS_BRANCH" == "$PUBLISH_BRANCH" ]; then
echo "We upload apk only for changes in development or master, and not PRs. So, let's skip this shall we ? :)"
exit 0
fi
Expand Down

0 comments on commit 39bba2f

Please sign in to comment.