A local-first personal finance app
Dispatch github ci jobs after running update-vrt workflow (#5586)
Matiss Janis Aboltins3a8eb96d76ac
diff --git a/.github/workflows/build.yml b/.github/workflows/build.ymlindex 955580ac7a..9a71995753 100644--- a/.github/workflows/build.yml+++ b/.github/workflows/build.yml@@ -12,9 +12,11 @@ on:branches:- masterpull_request:+ repository_dispatch:+ types: [vrt_updated]concurrency:- group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}+ group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.event.client_payload.pr_number || github.ref }}cancel-in-progress: ${{ github.ref != 'refs/heads/master' }}jobs:@@ -22,6 +24,8 @@ jobs:runs-on: ubuntu-lateststeps:- uses: actions/checkout@v4+ with:+ ref: ${{ github.event.client_payload.branch || github.ref }}- name: Set up environmentuses: ./.github/actions/setup- name: Build API@@ -38,6 +42,8 @@ jobs:runs-on: ubuntu-lateststeps:- uses: actions/checkout@v4+ with:+ ref: ${{ github.event.client_payload.branch || github.ref }}- name: Set up environmentuses: ./.github/actions/setup- name: Build CRDT@@ -54,6 +60,8 @@ jobs:runs-on: ubuntu-lateststeps:- uses: actions/checkout@v4+ with:+ ref: ${{ github.event.client_payload.branch || github.ref }}- name: Set up environmentuses: ./.github/actions/setup- name: Build Web@@ -73,6 +81,8 @@ jobs:runs-on: ubuntu-lateststeps:- uses: actions/checkout@v4+ with:+ ref: ${{ github.event.client_payload.branch || github.ref }}- name: Set up environmentuses: ./.github/actions/setup- name: Build Serverdiff --git a/.github/workflows/check.yml b/.github/workflows/check.ymlindex c7ebd00a7e..dd5c76a088 100644--- a/.github/workflows/check.yml+++ b/.github/workflows/check.yml@@ -5,9 +5,11 @@ on:branches:- masterpull_request:+ repository_dispatch:+ types: [vrt_updated]concurrency:- group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}+ group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.event.client_payload.pr_number || github.ref }}cancel-in-progress: ${{ github.ref != 'refs/heads/master' }}jobs:@@ -15,6 +17,8 @@ jobs:runs-on: ubuntu-lateststeps:- uses: actions/checkout@v4+ with:+ ref: ${{ github.event.client_payload.branch || github.ref }}- name: Set up environmentuses: ./.github/actions/setup- name: Lint@@ -23,6 +27,8 @@ jobs:runs-on: ubuntu-lateststeps:- uses: actions/checkout@v4+ with:+ ref: ${{ github.event.client_payload.branch || github.ref }}- name: Set up environmentuses: ./.github/actions/setup- name: Typecheck@@ -31,6 +37,8 @@ jobs:runs-on: ubuntu-lateststeps:- uses: actions/checkout@v4+ with:+ ref: ${{ github.event.client_payload.branch || github.ref }}- name: Set up environmentuses: ./.github/actions/setup- name: Build Web@@ -41,6 +49,8 @@ jobs:runs-on: ubuntu-lateststeps:- uses: actions/checkout@v4+ with:+ ref: ${{ github.event.client_payload.branch || github.ref }}- name: Set up environmentuses: ./.github/actions/setup- name: Test@@ -51,6 +61,8 @@ jobs:runs-on: ubuntu-lateststeps:- uses: actions/checkout@v4+ with:+ ref: ${{ github.event.client_payload.branch || github.ref }}- uses: actions/setup-node@v4with:node-version: 20diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.ymlindex 20780a5625..a031eb726a 100644--- a/.github/workflows/codeql.yml+++ b/.github/workflows/codeql.yml@@ -4,11 +4,13 @@ on:push:branches: [master]pull_request:+ repository_dispatch:+ types: [vrt_updated]schedule:- cron: '23 11 * * 6'concurrency:- group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}+ group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.event.client_payload.pr_number || github.ref }}cancel-in-progress: ${{ github.ref != 'refs/heads/master' }}jobs:@@ -23,6 +25,8 @@ jobs:steps:- name: Checkout repositoryuses: actions/checkout@v4+ with:+ ref: ${{ github.event.client_payload.branch || github.ref }}- name: Initialize CodeQLuses: github/codeql-action/init@v3diff --git a/.github/workflows/update-vrt.yml b/.github/workflows/update-vrt.ymlindex ccb19f6375..5304592fb2 100644--- a/.github/workflows/update-vrt.yml+++ b/.github/workflows/update-vrt.yml@@ -96,6 +96,17 @@ jobs:figit commit -m "Update VRT"git push origin HEAD:${BRANCH_NAME}+ - name: Trigger CI workflows+ uses: peter-evans/repository-dispatch@v3+ with:+ token: ${{ secrets.GITHUB_TOKEN }}+ event-type: vrt_updated+ client-payload: |+ {+ "pr_number": "${{ github.event.issue.number }}",+ "branch": "${{ steps.comment-branch.outputs.head_ref }}",+ "sha": "${{ steps.comment-branch.outputs.head_sha }}"+ }- name: Add finished reactionuses: dkershner6/reaction-action@v2with:diff --git a/upcoming-release-notes/5586.md b/upcoming-release-notes/5586.mdnew file mode 100644index 0000000000..17d0f0d5e5--- /dev/null+++ b/upcoming-release-notes/5586.md@@ -0,0 +1,7 @@+---+category: Enhancements+authors: [MatissJanis]+---++Add repository dispatch trigger to CI workflows for improved downstream job execution.+