Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

workflow to review probot PRs #149

Merged
merged 1 commit into from
Nov 21, 2024
Merged

workflow to review probot PRs #149

merged 1 commit into from
Nov 21, 2024

Conversation

robandpdx
Copy link
Collaborator

This pull request introduces a new GitHub Actions workflow to automatically review pull requests that involve bumping Probot dependencies. The workflow is triggered when a pull request is opened or reopened, and it posts a review requesting changes if certain conditions are met.

Copy link


=============================== Coverage summary ===============================
Statements   : 100% ( 150/150 )
Branches     : 100% ( 88/88 )
Functions    : 100% ( 27/27 )
Lines        : 100% ( 149/149 )
================================================================================

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 1 out of 1 changed files in this pull request and generated no suggestions.

Tip: Copilot only keeps its highest confidence comments to reduce noise and keep you focused. Learn more

Comment on lines +7 to +25
runs-on: ubuntu-latest
steps:
- name: Post review
if: startsWith(github.event.pull_request.title, 'Bump probot') || startsWith(github.event.pull_request.title, 'Bump @probot')
uses: actions/[email protected]
with:
script: |
const pull_number = context.payload.pull_request.number;
const owner = context.repo.owner;
const repo = context.repo.repo;
await github.request(`POST /repos/${owner}/${repo}/pulls/${pull_number}/reviews`, {
owner: owner,
repo: repo,
pull_number: pull_number,
body: '👋🏻🤖 The latest probot uses a newer octokit, which is not compatible with nock.\n\n' +
'The latest version of octokit uses [undici http client](https://github.com/nodejs/undici). Nock does not support undici. More details [here](https://github.com/nock/nock/issues/2183).',
event: 'REQUEST_CHANGES'
});

Check warning

Code scanning / CodeQL

Workflow does not contain permissions Medium

Actions Job or Workflow does not set permissions
@robandpdx robandpdx merged commit 7b9fb60 into main Nov 21, 2024
6 checks passed
@robandpdx robandpdx deleted the workflow-review-probot-prs branch November 21, 2024 01:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant