From ee00df151b1a5638f001ac242cc1c5bed414f91f Mon Sep 17 00:00:00 2001 From: pooneyy <85266337+pooneyy@users.noreply.github.com> Date: Sat, 4 Oct 2025 17:22:57 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=F0=9F=94=A7=20chore(renovate):=20improve?= =?UTF-8?q?=20workflow=20reliability=20and=20remove=20manual=20trigger?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - remove workflow_dispatch manual trigger input to simplify workflow - add file existence check before reading version file to prevent errors - remove [skip ci] flag from commit message as it's no longer needed --- .github/workflows/renovate-app-version.yml | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/.github/workflows/renovate-app-version.yml b/.github/workflows/renovate-app-version.yml index ff8a199ff..760fa5240 100644 --- a/.github/workflows/renovate-app-version.yml +++ b/.github/workflows/renovate-app-version.yml @@ -3,11 +3,7 @@ name: Update app version in Renovate Branches on: push: branches: [ 'renovate/*' ] - workflow_dispatch: - inputs: - manual-trigger: - description: 'Manually trigger Renovate' - default: '' + jobs: update-app-version: runs-on: ubuntu-latest @@ -50,8 +46,10 @@ jobs: if [[ $file == *"docker-compose.yml"* ]]; then app_name=$(echo $file | cut -d'/' -f 2) old_version=$(echo $file | cut -d'/' -f 3) - new_version=$(cat "apps/$app_name/${old_version}.version") - rm -f "apps/$app_name/${old_version}.version" - git add "apps/$app_name/*" && git commit -m "🔧 chore($app_name): update app version from $old_version to $new_version [skip ci]" --no-verify && git push || true + if [ -f "apps/$app_name/${old_version}.version" ]; then + new_version=$(cat "apps/$app_name/${old_version}.version") + rm -f "apps/$app_name/${old_version}.version" + git add "apps/$app_name/*" && git commit -m "🔧 chore($app_name): update app version from $old_version to $new_version" --no-verify && git push || true + fi fi done \ No newline at end of file From a8061d9521e13186af47b085525bd9d28c6f3460 Mon Sep 17 00:00:00 2001 From: pooneyy <85266337+pooneyy@users.noreply.github.com> Date: Sat, 4 Oct 2025 18:47:08 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=94=A7=20chore(ci):=20set=20the=20che?= =?UTF-8?q?ck=20status=20of=20the=20commit=20created=20by=20the=20workflow?= =?UTF-8?q?=20to=20pass?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/renovate-app-version.yml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.github/workflows/renovate-app-version.yml b/.github/workflows/renovate-app-version.yml index 760fa5240..f807cdfcb 100644 --- a/.github/workflows/renovate-app-version.yml +++ b/.github/workflows/renovate-app-version.yml @@ -9,6 +9,7 @@ jobs: runs-on: ubuntu-latest permissions: contents: write + statuses: write steps: - name: Checkout uses: actions/checkout@v4.3.0 @@ -19,6 +20,7 @@ jobs: run: | git config --local user.email "githubaction@githubaction.com" git config --local user.name "github-action" + gh auth login --with-token <<< "${{ github.token }}" - name: Get list of updated files by the last commit in this branch separated by space id: updated-files @@ -50,6 +52,13 @@ jobs: new_version=$(cat "apps/$app_name/${old_version}.version") rm -f "apps/$app_name/${old_version}.version" git add "apps/$app_name/*" && git commit -m "🔧 chore($app_name): update app version from $old_version to $new_version" --no-verify && git push || true + gh api --method POST -H "Accept: application/vnd.github+json" \ + -H "X-GitHub-Api-Version: 2022-11-28" \ + /repos/${{ github.repository }}/statuses/$(git show -s --format=%H) \ + -f 'state=success' \ + -f 'target_url=https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}' \ + -f 'description=CI/CD' \ + -f 'context=${{ github.workflow}}' fi fi done \ No newline at end of file