From cbb65b28e0a2de5ebc13eaf907aa7a2ac5e97234 Mon Sep 17 00:00:00 2001 From: Akos Eros Date: Tue, 10 Jun 2025 15:18:16 +0200 Subject: [PATCH 1/2] Run update metadata workflow only on pushes to main branch --- .github/workflows/update-metadata.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/update-metadata.yml b/.github/workflows/update-metadata.yml index 39f5889ab..3a00a0349 100644 --- a/.github/workflows/update-metadata.yml +++ b/.github/workflows/update-metadata.yml @@ -3,12 +3,13 @@ # validatedpatterns/docs/.github/workflows/metadata-docs.yml@main --- name: Update docs pattern metadata - on: push: paths: - "pattern-metadata.yaml" - ".github/workflows/update-metadata.yml" + branches: + - main jobs: update-metadata: From d615d54d4af4b02eef925dea06f1d681f9044b3c Mon Sep 17 00:00:00 2001 From: Akos Eros Date: Tue, 10 Jun 2025 15:18:43 +0200 Subject: [PATCH 2/2] Add rhdp-branch sync workflow. --- .github/workflows/sync-rhdp-branch.yml | 29 ++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 .github/workflows/sync-rhdp-branch.yml diff --git a/.github/workflows/sync-rhdp-branch.yml b/.github/workflows/sync-rhdp-branch.yml new file mode 100644 index 000000000..685ccb94d --- /dev/null +++ b/.github/workflows/sync-rhdp-branch.yml @@ -0,0 +1,29 @@ +# This is a job to be run in the validatedpatterns organization only. +# It tries to keep the rhdp-deploy branch uptodate by creating a PR from main +--- +name: Sync main to rhdp-deploy +on: + push: + branches: + - main + +jobs: + sync-branches: + if: | + github.repository_owner == 'validatedpatterns' + runs-on: ubuntu-latest + name: Git Sync branch + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Set up Node + uses: actions/setup-node@v4 + with: + node-version: 20 + - name: Opening pull request + id: pull + uses: mbaldessari/git-sync-branch@v0.2.0 + with: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + FROM_BRANCH: "main" + TO_BRANCH: "rhdp-deploy"