Skip to content

Commit

Permalink
Skip depup if the latest version doesn't match x.y.z (#10)
Browse files Browse the repository at this point in the history
  • Loading branch information
maruloop authored Feb 13, 2024
1 parent 6f77667 commit 106e386
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/depup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,17 @@ jobs:
file: Dockerfile
version_name: TERRAFORM_VERSION
repo: hashicorp/terraform
- name: Check if the latest version matches x.y.z
id: check_version
run: |
if [[ "${{ steps.depup.outputs.latest }}" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
echo "match=true" >> "$GITHUB_OUTPUT"
else
echo "match=false" >> "$GITHUB_OUTPUT"
fi
- name: Create Pull Request
if: steps.check_version.outputs.match == 'true'
uses: peter-evans/create-pull-request@v6
with:
token: ${{ secrets.GITHUB_TOKEN }}
Expand Down

0 comments on commit 106e386

Please sign in to comment.