Skip to content

ci: bump gradle/gradle-build-action from 2 to 3 in /.github/workflows… #7

ci: bump gradle/gradle-build-action from 2 to 3 in /.github/workflows…

ci: bump gradle/gradle-build-action from 2 to 3 in /.github/workflows… #7

name: Increase build number on pull request
on:
pull_request:
branches:
- main
permissions:
contents: write
jobs:
increase-build-number:

Check failure on line 12 in .github/workflows/increase-build-number.yaml

View workflow run for this annotation

GitHub Actions / .github/workflows/increase-build-number.yaml

Invalid workflow file

You have an error in your yaml syntax on line 12
if: !startsWith(github.event.pull_request.title, 'ci:')
name: Increase build number
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.ref }}
- name: Increase build number
id: increase-build-number
run: |
buildNumber=$(grep buildNumber= build-number.properties | cut -d'=' -f2)
buildNumber=$((buildNumber+1))
sed -i "s/buildNumber=.*/buildNumber=$buildNumber/" build-number.properties
echo "buildNumber=$buildNumber" >> $GITHUB_OUTPUT
- name: Commit and push changes
run: |
git config user.name github-actions
git add build-number.properties
git commit -m "chore: increase build number to ${{ steps.increase-build-number.outputs.buildNumber }}"
git push