You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ci: More information for new contributors (#35109)
Currently, mathlib adds a "new-contributor" tag to PRs from folks with fewer than 5 PRs merged. However, this is more of a flag to reviewers and doesn't directly provide information to the new contributors.
This PR introduces a flow where when the "new-contributor" tag is added to a PR, a comment is also added reminding the new contributor to read the Lifecycle of a PR document and notes some common pitfalls (in particular, that tag management is performed via PR comments).
Co-authored-by: Kevin H Wilson <[email protected]>
Co-authored-by: Kim Morrison <[email protected]>
for await (const response of github.paginate.iterator(
85
+
github.rest.issues.listComments,
86
+
{
87
+
issue_number: context.issue.number,
88
+
owner,
89
+
repo,
90
+
per_page: 100,
91
+
}
92
+
)) {
93
+
if (response.data.some(c => c.body.includes(WELCOME_MARKER))) {
94
+
alreadyWelcomed = true;
95
+
break;
96
+
}
97
+
}
98
+
99
+
if (!alreadyWelcomed) {
100
+
console.log('Posting welcome comment for new contributor...');
101
+
const body = [
102
+
WELCOME_MARKER,
103
+
'## Welcome new contributor!',
104
+
'Thank you for contributing to Mathlib! If you haven\'t done so already, please review our [contribution guidelines](https://leanprover-community.github.io/contribute/index.html), as well as the [style guide](https://leanprover-community.github.io/contribute/style.html) and [naming conventions](https://leanprover-community.github.io/contribute/naming.html).',
105
+
'',
106
+
'We use a [review queue](https://leanprover-community.github.io/queueboard/review_dashboard.html) to manage reviews. If your PR does not appear there, it is probably because it is not successfully building (i.e., it doesn\'t have a green checkmark), has the `awaiting-author` tag, or another reason described in the [Lifecycle of a PR](https://leanprover-community.github.io/contribute/index.html#lifecycle-of-a-pr).',
107
+
'',
108
+
'If you haven\'t already done so, please come to [https://leanprover.zulipchat.com/](https://leanprover.zulipchat.com/), introduce yourself, and mention your new PR.',
0 commit comments