generated from adobe/aem-boilerplate
-
Notifications
You must be signed in to change notification settings - Fork 169
38 lines (36 loc) · 973 Bytes
/
dispatch.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: Dispatch workflows
on:
push:
branches:
- main
- stage
jobs:
dispatch-dc:
name: Dispatch DC workflow
if: github.repository == 'adobecom/milo'
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- uses: dorny/paths-filter@v3
id: changes
with:
base: ${{ github.ref }}
filters: |
src:
- 'libs/**'
- if: steps.changes.outputs.src == 'true'
name: Trigger DC Workflow
uses: actions/github-script@v7
with:
github-token: ${{ secrets.DC_PAT }}
script: |
github.rest.actions.createWorkflowDispatch({
owner: 'adobecom',
repo: 'dc',
workflow_id: 'test-milo.yml',
ref: 'stage',
inputs: {
miloBranch: '${{ github.ref_name }}'
},
})