All Projects → peter-evans → find-comment

peter-evans / find-comment

Licence: MIT license
A GitHub action to find an issue or pull request comment

Programming Languages

typescript
32286 projects
javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to find-comment

action-setup-kube-tools
Github Action that setup Kubernetes tools (kubectl, kustomize, helm, kubeconform, conftest, yq, rancher, tilt, skaffold) very fast and cache them on the runner. Please [✩Star] if you're using it!
Stars: ✭ 45 (-44.44%)
Mutual labels:  github-action
probot-messages
Probot extension for communicating with repository maintainers
Stars: ✭ 13 (-83.95%)
Mutual labels:  github-issues
setup-bats
GitHub Action to setup BATS testing framework
Stars: ✭ 25 (-69.14%)
Mutual labels:  github-action
sentry-releases-action
A GitHub action that creates releases for Sentry.io.
Stars: ✭ 38 (-53.09%)
Mutual labels:  github-action
clang-format-action
GitHub Action for clang-format checking
Stars: ✭ 48 (-40.74%)
Mutual labels:  github-action
recent-activity
Add your recent activity to your profile readme!
Stars: ✭ 87 (+7.41%)
Mutual labels:  github-action
github-contribution-graph-action
🙈 This GitHub action will automatically push empty commits to one of your repositories.
Stars: ✭ 42 (-48.15%)
Mutual labels:  github-action
aws-assume-role
GitHub action to assume subsequent AWS roles
Stars: ✭ 22 (-72.84%)
Mutual labels:  github-action
restrict-cursing-action
Github Action to prevent cursing and bad language in issues and pull requests
Stars: ✭ 20 (-75.31%)
Mutual labels:  github-action
bug-hunter-game
Bug Hunter Game is an web service that turns GitHub Issues into a game.
Stars: ✭ 28 (-65.43%)
Mutual labels:  github-issues
action-dynamic-readme
~ Dynamic ReadME Generator ~
Stars: ✭ 29 (-64.2%)
Mutual labels:  github-action
GitInfo-Git-for-Google-Assistant
GitInfo is a conversational data retrieval bot for Github repositories. It provides a conversational experience to access information. Information that can be retrieved using GitInfo include: stars, latest commit details , no of forks , no of issues etc.
Stars: ✭ 18 (-77.78%)
Mutual labels:  github-issues
github-action-publish-binaries
Publish binaries when new releases are made.
Stars: ✭ 123 (+51.85%)
Mutual labels:  github-action
issue-inspector
🔎 Preview and jump to the most upvoted comments in github issues (which are probably solutions)
Stars: ✭ 41 (-49.38%)
Mutual labels:  github-issues
slsa-provenance-action
Github Action implementation of SLSA Provenance Generation
Stars: ✭ 34 (-58.02%)
Mutual labels:  github-action
new-issue
A fully customizable Github issues interface. Setup for your repo today!
Stars: ✭ 22 (-72.84%)
Mutual labels:  github-issues
action-github-workflow-sync
Github Action To Sync Github Action's Workflow Files Across Repositories
Stars: ✭ 51 (-37.04%)
Mutual labels:  github-action
mpv-winbuild
Use Github Action to build mpv for Windows with latest commit.
Stars: ✭ 78 (-3.7%)
Mutual labels:  github-action
github-action-wpe-site-deploy
A GitHub Action to deploy code directly to WP Engine.
Stars: ✭ 116 (+43.21%)
Mutual labels:  github-action
migu-sign
咪咕爱看签到获流量话费,通过 github action 来实现自动签到。
Stars: ✭ 20 (-75.31%)
Mutual labels:  github-action

Find Comment

CI GitHub Marketplace

A GitHub action to find an issue or pull request comment.

The action will output the comment ID of the comment matching the search criteria.

Usage

Find the first comment containing the specified string

      - name: Find Comment
        uses: peter-evans/find-comment@v2
        id: fc
        with:
          issue-number: 1
          body-includes: search string 1

Find the first comment by the specified author

      - name: Find Comment
        uses: peter-evans/find-comment@v2
        id: fc
        with:
          issue-number: 1
          comment-author: peter-evans

Find the first comment containing the specified string AND by the specified author

      - name: Find Comment
        uses: peter-evans/find-comment@v2
        id: fc
        with:
          issue-number: 1
          comment-author: peter-evans
          body-includes: search string 1

Find the first comment matching the specified regular expression

      - name: Find Comment
        uses: peter-evans/find-comment@v2
        id: fc
        with:
          issue-number: 1
          body-regex: '^.*search string 1.*$'

Find the last comment containing the specified string

      - name: Find Comment
        uses: peter-evans/find-comment@v2
        id: fc
        with:
          issue-number: 1
          body-includes: search string 1
          direction: last

Action inputs

Name Description Default
token GITHUB_TOKEN or a repo scoped PAT. GITHUB_TOKEN
repository The full name of the repository containing the issue or pull request. github.repository (Current repository)
issue-number The number of the issue or pull request in which to search.
comment-author The GitHub user name of the comment author.
body-includes A string to search for in the body of comments.
body-regex A regular expression to search for in the body of comments.
direction Search direction, specified as first or last first

Outputs

The comment-id, comment-body and comment-author of the matching comment found will be output for use in later steps. They will be empty strings if no matching comment was found. Note that in order to read the step outputs the action step must have an id.

Tip: Empty strings evaluate to zero in GitHub Actions expressions. e.g. If comment-id is an empty string steps.fc.outputs.comment-id == 0 evaluates to true.

      - name: Find Comment
        uses: peter-evans/find-comment@v2
        id: fc
        with:
          issue-number: 1
          body-includes: search string 1
      - run: |
          echo ${{ steps.fc.outputs.comment-id }}
          echo ${{ steps.fc.outputs.comment-body }}
          echo ${{ steps.fc.outputs.comment-author }}

Accessing issues and pull requests in other repositories

You can search the comments of issues and pull requests in another repository by using a PAT instead of GITHUB_TOKEN.

License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].