Skip to content
Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Find Triggering Pull Request

Finds the pull request associated with a triggered event

inputs:
  token:
    description: "GitHub token used for authentication"
    required: true

outputs:
  pr-number:
    description: "The pull request number, if found, otherwise undefined"

Usage:

on:
  workflow_run:
    types: completed
...
jobs:
  useful-job:
    runs-on: ubuntu-latest
    steps:
      - id: find-triggering-pr
        uses: peternied/find-triggering-pr@v1
        with:
          token: ${{ secrets.GITHUB_TOKEN }}

      - run: echo ${{ steps.find-triggering-pr.outputs.pr-number }}

Changelog

v1

  • Initial Release

About

Finds the pull request associated with a triggered event

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages