DaprBot pushing tag or to branch already triggers build. (#1238)

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
This commit is contained in:
Artur Souza 2025-03-06 19:56:03 -08:00 committed by GitHub
parent ed95feeaf4
commit ad917d215b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 19 deletions

View File

@ -53,22 +53,4 @@ jobs:
git remote set-url origin https://x-access-token:${{ secrets.DAPR_BOT_TOKEN }}@github.com/${GITHUB_REPOSITORY}.git
# Copy first to allow automation to use the latest version and not the release branch's version.
cp -R ./.github/scripts ${RUNNER_TEMP}/
${RUNNER_TEMP}/scripts/create-release.sh ${{ inputs.rel_version }}
trigger:
name: Triggers the Dapr SDK build
runs-on: ubuntu-latest
needs: create-release
steps:
- name: Identify build ref to trigger build and release.
run: |
if [[ "${{ inputs.rel_version }}" == *"SNAPSHOT"* ]]; then
echo "BUILD_GIT_REF=master" >> $GITHUB_ENV
else
echo "BUILD_GIT_REF=v${{ inputs.rel_version }}" >> $GITHUB_ENV
fi
- name: Triggers the build and release.
if: env.BUILD_GIT_REF != 'master'
env:
GITHUB_TOKEN: ${{ secrets.DAPR_BOT_TOKEN }}
run: |
gh workflow run build.yml --repo ${GITHUB_REPOSITORY} --ref '${{ env.BUILD_GIT_REF }}'
${RUNNER_TEMP}/scripts/create-release.sh ${{ inputs.rel_version }}