From c583aa4949c2b25304f86b51e983c462aae7dd2f Mon Sep 17 00:00:00 2001 From: Simon Chung Date: Mon, 19 Jan 2026 12:00:56 +0000 Subject: [PATCH 1/7] CMFSUPPORT-2426 Add auto_pr_creation_rdke_manifest yml file To support PR creation in middleware-manifest-rdke repo --- .../auto_pr_creation_rdke_manifest.yml | 60 +++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 .github/workflows/auto_pr_creation_rdke_manifest.yml diff --git a/.github/workflows/auto_pr_creation_rdke_manifest.yml b/.github/workflows/auto_pr_creation_rdke_manifest.yml new file mode 100644 index 0000000..11165a1 --- /dev/null +++ b/.github/workflows/auto_pr_creation_rdke_manifest.yml @@ -0,0 +1,60 @@ +name: Update Manifests on Meta Repo Merge + +on: + workflow_call: + secrets: + RDKCM_RDKE: + required: true + +jobs: + auto_pr_creation_rdkb_manifest: + runs-on: ubuntu-latest + if: github.event.pull_request.merged == true + steps: + - name: Checkout build_tools_workflows code + uses: actions/checkout@v4 + with: + repository: rdkcentral/build_tools_workflows + path: 'tools' + ref: develop + token: ${{ secrets.RDKCM_RDKE }} + + - name: Checkout Manifest Repository + uses: actions/checkout@v4 + with: + repository: 'rdkcentral/middleware-manifest-rdke' + path: 'manifest_repo' + ref: develop + token: ${{ secrets.RDKCM_RDKE }} + + - name: Update Git Config + env: + BOT_EMAIL: ${{ vars.RDKM_BOT_EMAIL }} + run: | + cd manifest_repo + git config user.name "bot" + git config user.email "$BOT_EMAIL" + cd .. + + - name: Set up Python + uses: actions/setup-python@v4 + with: + python-version: '3.x' + + - name: Install Python dependencies + run: | + python3 -m pip install --upgrade pip + pip install requests PyGithub GitPython + + - name: Run the update script + env: + GITHUB_TOKEN: ${{ secrets.RDKCM_RDKE }} + GITHUB_ORG: 'rdkcentral' + MANIFEST_REPO_PATH: ${{ github.workspace }}/manifest_repo + MANIFEST_REPO_NAME: 'rdkcentral/middleware-manifest-rdke' + PR_NUMBER: ${{ github.event.pull_request.number }} + BASE_BRANCH: ${{ github.event.pull_request.base.ref }} + run: | + cd manifest_repo + python3 ../tools/build_health_check_workflow_scripts/auto_pr_generation_manifest.py + cd .. From c2650e45d60582951582b524846951f8698b495b Mon Sep 17 00:00:00 2001 From: Simon Chung Date: Mon, 19 Jan 2026 15:32:01 +0000 Subject: [PATCH 2/7] CMFSUPPORT-2426 Add submanifest support in auto_pr_generation_manifest script --- .../auto_pr_generation_manifest.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/build_health_check_workflow_scripts/auto_pr_generation_manifest.py b/build_health_check_workflow_scripts/auto_pr_generation_manifest.py index eda6b65..905596a 100644 --- a/build_health_check_workflow_scripts/auto_pr_generation_manifest.py +++ b/build_health_check_workflow_scripts/auto_pr_generation_manifest.py @@ -156,6 +156,12 @@ def update_xml_files(manifest_repo_path, updates): project.set('revision', updates[project.get('name')]) file_changed = True + for submanifest in root.findall('submanifest'): + if submanifest.get('name') in updates and submanifest.get('revision') != updates[submanifest.get('name')]: + print("Updating {}: {} from {} to {}".format(xml_file, submanifest.get('name'), submanifest.get('revision'), updates[submanifest.get('name')])) + submanifest.set('revision', updates[submanifest.get('name')]) + file_changed = True + if file_changed: write_xml(root, xml_path) print("Updated {}".format(xml_file)) From 164c4bd694472a6dd78e5737a57fa1690d97003b Mon Sep 17 00:00:00 2001 From: Simon Chung Date: Mon, 19 Jan 2026 15:52:23 +0000 Subject: [PATCH 3/7] Add more logging --- .../auto_pr_generation_manifest.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/build_health_check_workflow_scripts/auto_pr_generation_manifest.py b/build_health_check_workflow_scripts/auto_pr_generation_manifest.py index 905596a..95398f0 100644 --- a/build_health_check_workflow_scripts/auto_pr_generation_manifest.py +++ b/build_health_check_workflow_scripts/auto_pr_generation_manifest.py @@ -146,17 +146,20 @@ def update_xml_files(manifest_repo_path, updates): for xml_file in xml_files: xml_path = os.path.join(manifest_repo_path, xml_file) + print("Checking {}".format(xml_file)) tree = ET.parse(xml_path) root = tree.getroot() file_changed = False for project in root.findall('project'): + print("Checking projects {}".format(project.get('name'))) if project.get('name') in updates and project.get('revision') != updates[project.get('name')]: print("Updating {}: {} from {} to {}".format(xml_file, project.get('name'), project.get('revision'), updates[project.get('name')])) project.set('revision', updates[project.get('name')]) file_changed = True for submanifest in root.findall('submanifest'): + print("Checking submanifests {}".format(submanifest.get('name'))) if submanifest.get('name') in updates and submanifest.get('revision') != updates[submanifest.get('name')]: print("Updating {}: {} from {} to {}".format(xml_file, submanifest.get('name'), submanifest.get('revision'), updates[submanifest.get('name')])) submanifest.set('revision', updates[submanifest.get('name')]) From 21e2ba092af2a97b95b00a45a660a6cf478eb690 Mon Sep 17 00:00:00 2001 From: Simon Chung Date: Mon, 19 Jan 2026 15:57:41 +0000 Subject: [PATCH 4/7] Use feature/CMFSUPPORT-2426 branch for auto_pr_generation_manifest script --- .github/workflows/auto_pr_creation_rdke_manifest.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/auto_pr_creation_rdke_manifest.yml b/.github/workflows/auto_pr_creation_rdke_manifest.yml index 11165a1..f25f333 100644 --- a/.github/workflows/auto_pr_creation_rdke_manifest.yml +++ b/.github/workflows/auto_pr_creation_rdke_manifest.yml @@ -16,7 +16,7 @@ jobs: with: repository: rdkcentral/build_tools_workflows path: 'tools' - ref: develop + ref: feature/CMFSUPPORT-2426 token: ${{ secrets.RDKCM_RDKE }} - name: Checkout Manifest Repository From e4e7f8476b439c489a6f629cda628ea43a440f6b Mon Sep 17 00:00:00 2001 From: Simon Chung Date: Mon, 19 Jan 2026 16:02:07 +0000 Subject: [PATCH 5/7] Use project in submanifest instead of name --- .../auto_pr_generation_manifest.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/build_health_check_workflow_scripts/auto_pr_generation_manifest.py b/build_health_check_workflow_scripts/auto_pr_generation_manifest.py index 95398f0..c384eba 100644 --- a/build_health_check_workflow_scripts/auto_pr_generation_manifest.py +++ b/build_health_check_workflow_scripts/auto_pr_generation_manifest.py @@ -159,10 +159,10 @@ def update_xml_files(manifest_repo_path, updates): file_changed = True for submanifest in root.findall('submanifest'): - print("Checking submanifests {}".format(submanifest.get('name'))) - if submanifest.get('name') in updates and submanifest.get('revision') != updates[submanifest.get('name')]: - print("Updating {}: {} from {} to {}".format(xml_file, submanifest.get('name'), submanifest.get('revision'), updates[submanifest.get('name')])) - submanifest.set('revision', updates[submanifest.get('name')]) + print("Checking submanifests {}".format(submanifest.get('project'))) + if submanifest.get('project') in updates and submanifest.get('revision') != updates[submanifest.get('project')]: + print("Updating {}: {} from {} to {}".format(xml_file, submanifest.get('project'), submanifest.get('revision'), updates[submanifest.get('project')])) + submanifest.set('revision', updates[submanifest.get('project')]) file_changed = True if file_changed: From fe3781e1c7e9a9f6c333bc006469c5dd098d4461 Mon Sep 17 00:00:00 2001 From: Simon Chung Date: Mon, 19 Jan 2026 17:09:15 +0000 Subject: [PATCH 6/7] Revert "Use feature/CMFSUPPORT-2426 branch for auto_pr_generation_manifest script" This reverts commit 21e2ba092af2a97b95b00a45a660a6cf478eb690. --- .github/workflows/auto_pr_creation_rdke_manifest.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/auto_pr_creation_rdke_manifest.yml b/.github/workflows/auto_pr_creation_rdke_manifest.yml index f25f333..11165a1 100644 --- a/.github/workflows/auto_pr_creation_rdke_manifest.yml +++ b/.github/workflows/auto_pr_creation_rdke_manifest.yml @@ -16,7 +16,7 @@ jobs: with: repository: rdkcentral/build_tools_workflows path: 'tools' - ref: feature/CMFSUPPORT-2426 + ref: develop token: ${{ secrets.RDKCM_RDKE }} - name: Checkout Manifest Repository From 30180ce8593e1762040d17fa8df5c2f6e5083fb6 Mon Sep 17 00:00:00 2001 From: Simon Chung Date: Mon, 19 Jan 2026 17:17:54 +0000 Subject: [PATCH 7/7] Fix name of auto_pr_creation_rdke_manifest yml file --- .github/workflows/auto_pr_creation_rdke_manifest.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/auto_pr_creation_rdke_manifest.yml b/.github/workflows/auto_pr_creation_rdke_manifest.yml index 11165a1..0ea1022 100644 --- a/.github/workflows/auto_pr_creation_rdke_manifest.yml +++ b/.github/workflows/auto_pr_creation_rdke_manifest.yml @@ -1,4 +1,4 @@ -name: Update Manifests on Meta Repo Merge +name: Update Manifests on Sub-manifest Repo Merge on: workflow_call: @@ -7,7 +7,7 @@ on: required: true jobs: - auto_pr_creation_rdkb_manifest: + auto_pr_creation_rdke_manifest: runs-on: ubuntu-latest if: github.event.pull_request.merged == true steps: