mirror of
https://github.com/python/cpython.git
synced 2025-09-30 20:31:52 +00:00
[3.6] Update make patchcheck
for blurb and NEWS.d (GH-3406)
(cherry picked from commit 1ba9469e9f
)
This commit is contained in:
parent
1fc47b40af
commit
e00e1b812c
1 changed files with 5 additions and 5 deletions
|
@ -211,10 +211,11 @@ def credit_given(file_paths):
|
||||||
return os.path.join('Misc', 'ACKS') in file_paths
|
return os.path.join('Misc', 'ACKS') in file_paths
|
||||||
|
|
||||||
|
|
||||||
@status("Misc/NEWS updated", modal=True)
|
@status("Misc/NEWS.d updated with `blurb`", modal=True)
|
||||||
def reported_news(file_paths):
|
def reported_news(file_paths):
|
||||||
"""Check if Misc/NEWS has been changed."""
|
"""Check if Misc/NEWS.d has been changed."""
|
||||||
return os.path.join('Misc', 'NEWS') in file_paths
|
return any(p.startswith(os.path.join('Misc', 'NEWS.d', 'next'))
|
||||||
|
for p in file_paths)
|
||||||
|
|
||||||
@status("configure regenerated", modal=True, info=str)
|
@status("configure regenerated", modal=True, info=str)
|
||||||
def regenerated_configure(file_paths):
|
def regenerated_configure(file_paths):
|
||||||
|
@ -260,8 +261,7 @@ def main():
|
||||||
c_files = [fn for fn in file_paths if fn.endswith(('.c', '.h'))]
|
c_files = [fn for fn in file_paths if fn.endswith(('.c', '.h'))]
|
||||||
doc_files = [fn for fn in file_paths if fn.startswith('Doc') and
|
doc_files = [fn for fn in file_paths if fn.startswith('Doc') and
|
||||||
fn.endswith(('.rst', '.inc'))]
|
fn.endswith(('.rst', '.inc'))]
|
||||||
misc_files = {os.path.join('Misc', 'ACKS'), os.path.join('Misc', 'NEWS')}\
|
misc_files = {p for p in file_paths if p.startswith('Misc')}
|
||||||
& set(file_paths)
|
|
||||||
# PEP 8 whitespace rules enforcement.
|
# PEP 8 whitespace rules enforcement.
|
||||||
normalize_whitespace(python_files)
|
normalize_whitespace(python_files)
|
||||||
# C rules enforcement.
|
# C rules enforcement.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue