Skip to content

Commit

Permalink
Merge branch 'towncrier' of https://github.com/DudeNr33/pylint into t…
Browse files Browse the repository at this point in the history
…owncrier
  • Loading branch information
DudeNr33 committed Jul 13, 2022
2 parents 2c5bc8c + d43f86e commit cd62b62
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ To ease the process of reviewing your PR, do make sure to complete the following
- [ ] Create a news fragment with `towncrier create <IssueNumber>.<type>` which will be
included in the changelog. `<type>` can be one of: new_check, removed_check, extension,
false_positive, false_negative, bugfix, other, internal. If necessary you can write
details of offer examples on how the new change is supposed to work.
details or offer examples on how the new change is supposed to work.
- [ ] If you used multiple emails or multiple names when contributing, add your mails
and preferred name in ``script/.contributors_aliases.json``
-->
Expand Down
2 changes: 1 addition & 1 deletion doc/development_guide/contributor_guide/contribute.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ your patch gets accepted:
- Create a news fragment with `towncrier create <IssueNumber>.<type>` which will be
included in the changelog. `<type>` can be one of: new_check, removed_check, extension,
false_positive, false_negative, bugfix, other, internal. If necessary you can write
details of offer examples on how the new change is supposed to work.
details or offer examples on how the new change is supposed to work.

- Document your change, if it is a non-trivial one.

Expand Down
24 changes: 17 additions & 7 deletions script/check_newsfragments.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,13 +59,23 @@ def check_file(file: Path, verbose: bool) -> bool:
print(f"Checked '{file}': LGTM 🤖👍")
return True
print(
f"{file}: does not respect the standard format 🤖👎\n\n"
"The standard format is:\n\n"
"<one or more line of text>\n"
"<one blank line>\n"
"<issue reference>\n\n"
"where <issue reference> can be one of:\n"
f"{', '.join(VALID_ISSUES_KEYWORDS)}"
f"""\
{file}: does not respect the standard format 🤖👎
The standard format is:
<one or more line of text>
<one blank line>
<issue reference> #<issuenumber>
Where <issue reference> can be one of: {', '.join(VALID_ISSUES_KEYWORDS)}
For example:
``pylint.x.y`` is now a private API.
Refs #1234
"""
)
return False

Expand Down

0 comments on commit cd62b62

Please sign in to comment.