From abaf21f0c6648a175aff11ebde7c40b31a3c8c9d Mon Sep 17 00:00:00 2001 From: Robert Dyer Date: Fri, 13 Dec 2024 11:30:08 -0600 Subject: [PATCH] fix workflow permission --- .github/workflows/actual-release.yml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/actual-release.yml b/.github/workflows/actual-release.yml index ee4e402..5a52ad1 100644 --- a/.github/workflows/actual-release.yml +++ b/.github/workflows/actual-release.yml @@ -10,17 +10,23 @@ on: jobs: get-version: runs-on: ubuntu-latest + + permissions: + contents: write + steps: - - uses: actions/checkout@v4 - with: - token: ${{ secrets.REPO_SCOPED_TOKEN }} + - name: Checkout repository + uses: actions/checkout@v4 + - name: Fetch release version run: | curl -sL https://api.github.com/repos/actualbudget/actual/releases/latest | \ jq -r ".tag_name" > actual-latest.txt + - name: Check for modified files id: git-check run: echo ::set-output name=modified::$([ -z "`git status --porcelain`" ] && echo "false" || echo "true") + - name: Commit latest release version if: steps.git-check.outputs.modified == 'true' run: |