diff --git a/.github/auto-tag.sh b/.github/auto-tag.sh index ffb627e9..a9b31372 100755 --- a/.github/auto-tag.sh +++ b/.github/auto-tag.sh @@ -1,5 +1,5 @@ #!/bin/bash -set -euxo pipefail +set -euo pipefail script_folder=$(dirname "${BASH_SOURCE[0]}") source "${script_folder}"/funcs.sh diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 95c6c2ac..d001684a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,6 +2,7 @@ name: CI on: push: + tags: ['v*'] branches: - main pull_request: diff --git a/.github/workflows/tag.yml b/.github/workflows/tag.yml index 3464ba1e..b9daaa8e 100644 --- a/.github/workflows/tag.yml +++ b/.github/workflows/tag.yml @@ -6,9 +6,6 @@ on: types: - completed - push: - tags: ['v*'] - jobs: auto-git-and-semver-tag: runs-on: ubuntu-latest @@ -43,11 +40,11 @@ jobs: PR_NUMBER: '${{ fromJson(steps.get_pr_data.outputs.result).number }}' run: | echo "Attempting to auto-tag merge commit" - script_output=$(set -e; .github/auto-tag.sh "${PR_BODY}" "${PR_NUMBER}") + script_output=$(.github/auto-tag.sh "${PR_BODY}" "${PR_NUMBER}") if $? != 0; then exit 1 fi - script_output=$(set -e; echo "${new_tag}" | tail -n 1) + script_output=$(echo "${new_tag}" | tail -n 1) echo "New tag version: ${script_output}" echo "new_tag=${script_output}" >> "$GITHUB_OUTPUT"