Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
235380b4
Commit
235380b4
authored
Feb 22, 2012
by
Nadeem Vawda
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue #14053: Fix "make patchcheck" to work with MQ.
Patch by Francisco Martín Brugué
parent
e70ddf27
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
0 deletions
+20
-0
Misc/ACKS
Misc/ACKS
+1
-0
Misc/NEWS
Misc/NEWS
+3
-0
Tools/scripts/patchcheck.py
Tools/scripts/patchcheck.py
+16
-0
No files found.
Misc/ACKS
View file @
235380b4
...
@@ -108,6 +108,7 @@ Jean Brouwers
...
@@ -108,6 +108,7 @@ Jean Brouwers
Gary S. Brown
Gary S. Brown
Oleg Broytmann
Oleg Broytmann
Dave Brueck
Dave Brueck
Francisco Martín Brugué
Stan Bubrouski
Stan Bubrouski
Erik de Bueger
Erik de Bueger
Dick Bulterman
Dick Bulterman
...
...
Misc/NEWS
View file @
235380b4
...
@@ -531,6 +531,9 @@ Build
...
@@ -531,6 +531,9 @@ Build
Tools/Demos
Tools/Demos
-----------
-----------
- Issue #14053: patchcheck.py ("make patchcheck") now works with MQ patches.
Patch by Francisco Martín Brugué.
- Issue #13930: 2to3 is now able to write its converted output files to another
- Issue #13930: 2to3 is now able to write its converted output files to another
directory tree as well as copying unchanged files and altering the file
directory tree as well as copying unchanged files and altering the file
suffix. See its new -o, -W and --add-suffix options. This makes it more
suffix. See its new -o, -W and --add-suffix options. This makes it more
...
...
Tools/scripts/patchcheck.py
View file @
235380b4
...
@@ -36,6 +36,20 @@ def status(message, modal=False, info=None):
...
@@ -36,6 +36,20 @@ def status(message, modal=False, info=None):
return
decorated_fxn
return
decorated_fxn
def
mq_patches_applied
():
"""Check if there are any applied MQ patches."""
cmd
=
'hg qapplied'
st
=
subprocess
.
Popen
(
cmd
.
split
(),
stdout
=
subprocess
.
PIPE
,
stderr
=
subprocess
.
PIPE
)
try
:
bstdout
,
_
=
st
.
communicate
()
return
st
.
returncode
==
0
and
bstdout
finally
:
st
.
stdout
.
close
()
st
.
stderr
.
close
()
@
status
(
"Getting the list of files that have been added/changed"
,
@
status
(
"Getting the list of files that have been added/changed"
,
info
=
lambda
x
:
n_files_str
(
len
(
x
)))
info
=
lambda
x
:
n_files_str
(
len
(
x
)))
def
changed_files
():
def
changed_files
():
...
@@ -43,6 +57,8 @@ def changed_files():
...
@@ -43,6 +57,8 @@ def changed_files():
if
os
.
path
.
isdir
(
os
.
path
.
join
(
SRCDIR
,
'.hg'
)):
if
os
.
path
.
isdir
(
os
.
path
.
join
(
SRCDIR
,
'.hg'
)):
vcs
=
'hg'
vcs
=
'hg'
cmd
=
'hg status --added --modified --no-status'
cmd
=
'hg status --added --modified --no-status'
if
mq_patches_applied
():
cmd
+=
' --rev qparent'
elif
os
.
path
.
isdir
(
'.svn'
):
elif
os
.
path
.
isdir
(
'.svn'
):
vcs
=
'svn'
vcs
=
'svn'
cmd
=
'svn status --quiet --non-interactive --ignore-externals'
cmd
=
'svn status --quiet --non-interactive --ignore-externals'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment