Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Unified Diff: tools/revert.py

Issue 10919308: Reapply revert script. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/revert.py
===================================================================
--- tools/revert.py (revision 12406)
+++ tools/revert.py (working copy)
@@ -79,7 +79,8 @@
'Changes not staged for commit:' in line):
return True
if is_git:
- p = subprocess.Popen(['git', 'log', '-1'], stdout=subprocess.PIPE, shell=True)
+ p = subprocess.Popen(['git', 'log', '-1'], stdout=subprocess.PIPE,
+ shell=(platform.system()=='Windows'))
output, _ = p.communicate()
if find_git_info(output) == None:
return True
@@ -101,10 +102,12 @@
def runs_git():
"""Returns True if we're standing in an svn-git repository."""
p = subprocess.Popen(['svn', 'info'], stdout=subprocess.PIPE,
- stderr=subprocess.PIPE, shell=True)
+ stderr=subprocess.PIPE,
+ shell=(platform.system()=='Windows'))
output, err = p.communicate()
if err != None and 'is not a working copy' in err:
- p = subprocess.Popen(['git', 'status'], stdout=subprocess.PIPE, shell=True)
+ p = subprocess.Popen(['git', 'status'], stdout=subprocess.PIPE,
+ shell=(platform.system()=='Windows'))
output, _ = p.communicate()
if 'fatal: Not a git repository' in output:
maybe_fail('Error: not running git or svn.')
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698