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

Unified Diff: tools/testing/perf_testing/create_graph.py

Issue 9677056: Add git svn support to create_graph.py. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 9 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/testing/perf_testing/create_graph.py
diff --git a/tools/testing/perf_testing/create_graph.py b/tools/testing/perf_testing/create_graph.py
index a3fe757ea3865ae3cabd57565640597d9bc52d31..cc92f4099fcee55be263f6f070e09bbfa49d13f5 100755
--- a/tools/testing/perf_testing/create_graph.py
+++ b/tools/testing/perf_testing/create_graph.py
@@ -276,12 +276,23 @@ class TestRunner(object):
def add_svn_revision_to_trace(self, outfile):
"""Add the svn version number to the provided tracefile."""
- p = subprocess.Popen(['svn', 'info'], stdout = subprocess.PIPE,
+ p = subprocess.Popen(['svn', 'info'], stdout = subprocess.PIPE,
stderr = subprocess.STDOUT, shell = HAS_SHELL)
output, not_used = p.communicate()
for line in output.split('\n'):
if 'Revision' in line:
run_cmd(['echo', line.strip()], outfile)
+ return
+
+ # If svn did not work, try git svn.
+ p = subprocess.Popen(['git', 'svn', 'info'], stdout = subprocess.PIPE,
+ stderr = subprocess.STDOUT, shell = HAS_SHELL)
+ output, not_used = p.communicate()
+ for line in output.split('\n'):
+ if 'Revision' in line:
+ run_cmd(['echo', line.strip()], outfile)
Emily Fortuna 2012/03/13 18:18:04 This is fine, or pass the list ['svn', 'info'] and
+ return
+
def write_html(self, delimiter, rev_nums, label_1, dict_1, label_2, dict_2,
cleanFile=False):
@@ -756,4 +767,3 @@ def main():
if __name__ == '__main__':
main()
-
« 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