A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/Skenvy/dispatch-suggestor below:

Skenvy/dispatch-suggestor: Suggests relevant dispatchable workflows for a PR branch that would otherwise trigger the dispatchable workflows from pushes to the trunk.

See it on the 🏪 marketplace.

Suggests dispatchable workflows for a branch that would otherwise trigger the dispatchable workflows from pushes to the trunk.

- name: Dispatch 📤 Suggestor 📥
  uses: Skenvy/dispatch-suggestor@v1
  with:
    github_token: ${{ secrets.GITHUB_TOKEN }}

Embed the action in a workflow triggered on pull_request events, and it will determine a list of workflows with workflow_dispatch triggers that would also be triggered on push to the trunk branch (but that aren't triggered by pushing to the PR's head branch).

E.g. if you have several workflow_dispatch based workflows that are each also triggered by pushes to the trunk branch but limited to specific file triggers, this action will evaluate the changes in the PR and determine for each dispatchable workflow if they are relevant or not, and then suggest the ones it considers relevant.

list-workflows-pagination-limit Inputs -- more niche options comment-unique-identifier Inputs -- logging options list-of-dispatchable-workflows The recommended on: to use for the workflow
on:
  pull_request:
    branches:
    - 'main'
Checkout: In jobs.<job_id>.steps[*]
- name: 🏁 Checkout
  uses: actions/checkout@v4
  with:
    sparse-checkout: |
      .github/workflows/*.y*ml
    sparse-checkout-cone-mode: false
this: In jobs.<job_id>.steps[*].uses:
- uses: Skenvy/dispatch-suggestor@v1
  with:
    github_token: ${{ secrets.GITHUB_TOKEN }}

See this example here.

name: Dispatch 📤 Suggestor 📥
on:
  pull_request:
permissions:
  actions: read
  contents: read
  pull-requests: write
jobs:
  suggestor:
    name: Dispatch 📤 Suggestor 📥
    runs-on: 'ubuntu-latest'
    steps:
    - name: 🏁 Checkout
      uses: actions/checkout@v4
      with:
        sparse-checkout: |
          .github/workflows/*.y*ml
        sparse-checkout-cone-mode: false
    - name: Dispatch 📤 Suggestor 📥
      id: dispatch-suggestor
      uses: Skenvy/dispatch-suggestor@v1
      with:
        github_token: ${{ secrets.GITHUB_TOKEN }}
    - name: List changed files
      run: echo "${{ steps.dispatch-suggestor.outputs.list-of-changed-files }}"
    - name: List dispatchable workflows
      run: echo "${{ steps.dispatch-suggestor.outputs.list-of-dispatchable-workflows }}"

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4