Skip to content

Github Action that verifies if a given user has left a comment in a pull-request

License

Notifications You must be signed in to change notification settings

peterkrauz/search-pull-request-comments-action

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

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Search pull-request comments Action

Searches a pull-request for any comment left by a specific user. If no comment is found, the step fails. Searches through both simple and review comments.

Installation

On .github/workflows/, create a file pr_comment_search.yml:

name: <name goes here>
on: pull_request

jobs:
  search_pull_request_comments:
    runs-on: ubuntu-latest
    container: python:3.7-slim

    steps:
      - name: Search pull-request comments
        uses: peterkrauz/search-pull-request-comments@v0.0.8
        env:
          REQUIRED_COMMENT_USER: "john-doe"
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          EVENT_DETAILS: ${{ toJSON(github.event) }}

In this setup, the step will succeed if there's any comment written by john-doe in your pull-request. If john-doe did not comment in this pull-request, the job will fail.

About

Github Action that verifies if a given user has left a comment in a pull-request

Resources

License

Stars

Watchers

Forks

Packages

No packages published