Skip to content

Commit

Permalink
Merge pull request #79 from vdice/ci/add-dispatch-workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
radu-matei committed Jul 13, 2022
2 parents 6426e2e + cbcd886 commit 23a4472
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/dispatch.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Dispatch Event

on:
push:
branches: [main, "v*"]
tags: ["v*"]

jobs:
changes:
name: Detect files changed
runs-on: ubuntu-latest
if: ${{ github.repository_owner == 'fermyon' }}
outputs:
docs: ${{ steps.filter.outputs.docs }}
steps:
- uses: actions/checkout@v2
- uses: dorny/paths-filter@v2
id: filter
with:
filters: |
docs:
- 'docs/**'
dispatch:
name: Dispatch bartholomew-docs-updated event
needs: changes
if: ${{ needs.changes.outputs.docs == 'true' }}
runs-on: ubuntu-latest
steps:
- name: Repository Dispatch
uses: peter-evans/repository-dispatch@v2
with:
token: ${{ secrets.DEST_REPO_ACCESS_TOKEN }}
repository: ${{ secrets.DEST_REPO }}
event-type: bartholomew-docs-updated
client-payload: '{"ref": "${{ github.ref }}", "sha": "${{ github.sha }}"}'

0 comments on commit 23a4472

Please sign in to comment.