Files
alfresco-ng2-components/.github/workflows/package_dispatch.yml
T
dependabot[bot] 747da93b0f build(deps): bump actions/github-script from 8.0.0 to 9.0.0 (#11804)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-13 10:09:22 +02:00

33 lines
1.1 KiB
YAML

name: Package published
on:
registry_package:
types: [published]
jobs:
build:
runs-on: ubuntu-latest
if: github.event.registry_package.package_type == 'npm' && github.event.registry_package.name == 'adf-core'
steps:
- name: Dispatch event to monorepo
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
PACKAGE_NAME: ${{ github.event.registry_package.name }}
PACKAGE_VERSION: ${{ github.event.registry_package.package_version.name }}
with:
github-token: ${{ secrets.PAT_WRITE_PKG }}
retries: 3
script: |
const payload = {
package_name: process.env.PACKAGE_NAME,
package_version: process.env.PACKAGE_VERSION
};
await github.rest.repos.createDispatchEvent({
owner: context.repo.owner,
repo: "alfresco-apps",
event_type: "package-published",
client_payload: payload
});
console.log(`Trigger a dispatch event for the monorepo`);