Files
zigbee-OTA/.github/workflows/reprocess_all_images.yml
dependabot[bot] 29e7316473 Bump pnpm/action-setup from 5 to 6
Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 5 to 6.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v5...v6)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-04-13 18:11:05 +00:00

72 lines
2.6 KiB
YAML

name: Re-Process All Images
on:
workflow_dispatch:
inputs:
remove_not_in_manifest:
description: 'Remove images not found in manifest (if false, will be moved to separate dir instead).'
required: true
default: false
type: boolean
# skip_download_third_parties:
# description: 'Skip the step that downloads firmware with 3rd party URLs in manifest.'
# required: true
# default: true
# type: boolean
permissions:
contents: write
pull-requests: write
jobs:
reprocess-all-images:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: pnpm/action-setup@v6
- uses: actions/setup-node@v6
with:
node-version: 24
registry-url: https://registry.npmjs.org/
cache: pnpm
- name: Install dependencies
run: pnpm i --frozen-lockfile
- name: Build
run: pnpm run build
- name: Create and checkout new branch
id: create_branch
run: |
git config --global user.name 'github-actions[bot]'
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
branch_name="reprocess-$(date +'%Y-%m-%d-%H-%M-%S')"
echo "branch_name=$branch_name" >> $GITHUB_OUTPUT
git checkout -b $branch_name
- name: Reprocess
uses: actions/github-script@v8
env:
NODE_EXTRA_CA_CERTS: cacerts.pem
with:
script: |
const {reProcessAllImages} = await import("${{ github.workspace }}/dist/ghw_reprocess_all_images.js")
await reProcessAllImages(github, core, context, ${{ fromJSON(inputs.remove_not_in_manifest) }}, true)
- name: Commit changes in new branch
run: |
git add .
git commit -m "Re-Processed all images" || echo 'Nothing to commit'
git push -u origin HEAD
- name: Create pull request
uses: actions/github-script@v8
with:
script: |
const {createPRToDefault} = await import("${{ github.workspace }}/dist/ghw_create_pr_to_default.js")
await createPRToDefault(github, core, context, "${{steps.create_branch.outputs.branch_name}}", "Re-Processed all images")