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

Side by Side Diff: tools/metrics/histograms/update_extension_functions.py

Issue 1143323006: Histograms.xml python script housekeeping (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@bad_message
Patch Set: Fix imports (sadface) Created 5 years, 6 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 unified diff | Download patch
OLDNEW
1 # Copyright 2013 The Chromium Authors. All rights reserved. 1 # Copyright 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 """Updates ExtensionFunctions enum in histograms.xml file with values read from 5 """Updates ExtensionFunctions enum in histograms.xml file with values read from
6 extension_function_histogram_value.h. 6 extension_function_histogram_value.h.
7 7
8 If the file was pretty-printed, the updated version is pretty-printed too. 8 If the file was pretty-printed, the updated version is pretty-printed too.
9 """ 9 """
10 10
11 import os 11 import os
12 import sys 12 import sys
13 13
14 from update_histogram_enum import UpdateHistogramEnum 14 from update_histogram_enum import UpdateHistogramEnum
15 15
16 if __name__ == '__main__': 16 if __name__ == '__main__':
17 if len(sys.argv) > 1: 17 if len(sys.argv) > 1:
18 print >>sys.stderr, 'No arguments expected!' 18 print >>sys.stderr, 'No arguments expected!'
19 sys.stderr.write(__doc__) 19 sys.stderr.write(__doc__)
20 sys.exit(1) 20 sys.exit(1)
21 21
22 source_header = 'extensions/browser/extension_function_histogram_value.h'
22 UpdateHistogramEnum(histogram_enum_name='ExtensionFunctions', 23 UpdateHistogramEnum(histogram_enum_name='ExtensionFunctions',
23 source_enum_path= 24 source_enum_path=source_header,
24 os.path.join('..', '..', '..', 'extensions',
25 'browser',
26 'extension_function_histogram_value.h'),
27 start_marker='^enum HistogramValue {', 25 start_marker='^enum HistogramValue {',
28 end_marker='^ENUM_BOUNDARY') 26 end_marker='^ENUM_BOUNDARY')
OLDNEW
« no previous file with comments | « tools/metrics/histograms/update_editor_commands.py ('k') | tools/metrics/histograms/update_extension_permission.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698