From dd190f7c8a266fb8852952028c13479968ec8d23 Mon Sep 17 00:00:00 2001 From: WerWolv Date: Sun, 19 Mar 2023 11:22:55 +0100 Subject: [PATCH] git: Added documentation dispatch workflow --- .github/workflows/dispatch.yml | 45 ++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 .github/workflows/dispatch.yml diff --git a/.github/workflows/dispatch.yml b/.github/workflows/dispatch.yml new file mode 100644 index 0000000..6d2569d --- /dev/null +++ b/.github/workflows/dispatch.yml @@ -0,0 +1,45 @@ +name: "Unit Tests" + +on: + push: + branches: [ '*' ] + pull_request: + branches: [ '*' ] + repository_dispatch: + types: [run_tests] + workflow_dispatch: + inputs: + generate_docs: + description: "Regenerate docs" + required: false + type: boolean + +jobs: + tests: + name: ๐Ÿงช Unit Tests + runs-on: ubuntu-22.04 + permissions: + actions: read + contents: read + security-events: write + + steps: + - name: ๐Ÿงฐ Checkout + uses: actions/checkout@v2 + with: + submodules: recursive + + - name: ๐Ÿ“„ Check changed include files + id: changed-includes + uses: tj-actions/changed-files@v35 + with: + files: includes/**/*.pat + + - name: โœ‰๏ธ Run Documentation generator + if: ${{ env.DISPATCH_TOKEN != '' && (steps.changed-includes.outputs.any_changed == 'true' || inputs.generate_docs) }} + uses: mvasigh/dispatch-action@main + with: + token: ${{ secrets.DISPATCH_TOKEN }} + repo: Documentation + owner: WerWolv + event_type: update_pl_docs