From 2f431883a266976cb92dbaebb96e9bdbde599e34 Mon Sep 17 00:00:00 2001 From: Marco Carrozzo Date: Wed, 11 Jan 2023 12:35:23 +0100 Subject: [PATCH] set branch --- .github/workflows/git-tag.yml | 2 +- scripts/travis/release/git-tag.sh | 13 ++++--------- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/.github/workflows/git-tag.yml b/.github/workflows/git-tag.yml index 7f4d9712df..9837a5094b 100644 --- a/.github/workflows/git-tag.yml +++ b/.github/workflows/git-tag.yml @@ -85,4 +85,4 @@ jobs: - name: "Release tag" run: | git fetch --all --quiet - set -u; TRAVIS_BRANCH=master bash -x ./scripts/travis/release/git-tag.sh ${{ steps.set-dryrun.outputs.dryrun }} + set -u; TRAVIS_BRANCH=${GITHUB_REF##*/} bash -x ./scripts/travis/release/git-tag.sh ${{ steps.set-dryrun.outputs.dryrun }} diff --git a/scripts/travis/release/git-tag.sh b/scripts/travis/release/git-tag.sh index 9dc0be724b..899212367c 100755 --- a/scripts/travis/release/git-tag.sh +++ b/scripts/travis/release/git-tag.sh @@ -9,20 +9,15 @@ fi; echo "git tag -a ${VERSION} -m ${VERSION}" git config --local user.name "alfresco-build" git config --local user.email "build@alfresco.com" -# git tag -a ${VERSION} -m "${VERSION} [ci skip] " +git tag -a ${VERSION} -m "${VERSION} [ci skip] " git remote rm origin GITHUB_REPO=https://$GITHUB_TOKEN:x-oauth-basic@github.com/Alfresco/alfresco-ng2-components.git git remote add origin $GITHUB_REPO if [[ "$1" == "--dryrun" ]]; then - echo "dry run"; + echo "Dry run enabled. Nothing is changed"; git tag | grep "${VERSION}" - git switch -c AAE-12037-dev - touch dev.test - git add dev.test - git commit -m "add dev.test" - git push origin AAE-12037-dev else - echo "LIVE!" - # git push origin --tags + echo "Pushing new tag ${VERSION}!" + #git push origin --tags fi;