Add Reusable Workflow test

This commit is contained in:
Alvaro Muñoz
2024-02-08 15:11:39 +01:00
parent 5006ffe203
commit db413361f7
2 changed files with 36 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
on: push
jobs:
call-workflow-1-in-local-repo:
uses: octo-org/this-repo/.github/workflows/reusable_workflow.yml@172239021f7ba04fe7327647b213799853a9eb89
with:
config-path: ${{ github.event.pull_request.head.ref }}
secrets: inherit
call-workflow-2-in-local-repo:
uses: ./.github/workflows/reusable_workflow.yml
with:
config-path: ${{ github.event.pull_request.head.ref }}
secrets: inherit
call-workflow-in-another-repo:
uses: octo-org/another-repo/.github/workflows/workflow.yml@v1
with:
config-path: ${{ github.event.pull_request.head.ref }}
secrets: inherit

View File

@@ -0,0 +1,18 @@
name: Reusable workflow example
on:
workflow_call:
inputs:
config-path:
required: true
type: string
secrets:
token:
required: true
jobs:
triage:
runs-on: ubuntu-latest
steps:
- id: sink
run: echo ${{ inputs.config-path }}