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

Side by Side Diff: third_party/closure_compiler/tools/create_include_gyp.py

Issue 2754733002: Closure: remove pending_compiler_externs.js (Closed)
Patch Set: remove Created 3 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 unified diff | Download patch
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright 2016 The Chromium Authors. All rights reserved. 2 # Copyright 2016 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 # 5 #
6 # Usage: 6 # Usage:
7 # 7 #
8 # cd third_party/closure_compiler 8 # cd third_party/closure_compiler
9 # tools/create_include_gyp.py externs > externs/compiled_resources2.gyp 9 # tools/create_include_gyp.py externs > externs/compiled_resources2.gyp
10 # tools/create_include_gyp.py interfaces > interfaces/compiled_resources2.gyp 10 # tools/create_include_gyp.py interfaces > interfaces/compiled_resources2.gyp
(...skipping 28 matching lines...) Expand all
39 39
40 def CreateIncludeGyp(directory): 40 def CreateIncludeGyp(directory):
41 include_dir = os.path.join(os.path.dirname(__file__), "..", directory) 41 include_dir = os.path.join(os.path.dirname(__file__), "..", directory)
42 include_files = [f for f in os.listdir(include_dir) if f.endswith('.js')] 42 include_files = [f for f in os.listdir(include_dir) if f.endswith('.js')]
43 include_files.sort() 43 include_files.sort()
44 targets = [_TARGET_TEMPLATE % f[:-3] for f in include_files] 44 targets = [_TARGET_TEMPLATE % f[:-3] for f in include_files]
45 return _INCLUDE_TEMPLATE % (date.today().year, ",".join(targets).strip()) 45 return _INCLUDE_TEMPLATE % (date.today().year, ",".join(targets).strip())
46 46
47 47
48 def ShowUsageAndDie(): 48 def ShowUsageAndDie():
49 print "usage: tools/create_include_gyp.py externs > externs/compiled_resources 2.gyp" 49 print "usage: tools/create_include_gyp.py externs/ > externs/compiled_resource s2.gyp"
50 sys.exit(1) 50 sys.exit(1)
51 51
52 52
53 if __name__ == "__main__": 53 if __name__ == "__main__":
54 if len(sys.argv) != 2: 54 if len(sys.argv) != 2:
55 ShowUsageAndDie() 55 ShowUsageAndDie()
56 56
57 print CreateIncludeGyp(sys.argv[1]) 57 print CreateIncludeGyp(sys.argv[1])
OLDNEW
« no previous file with comments | « third_party/closure_compiler/externs/pending_compiler_externs.js ('k') | ui/webui/resources/js/compiled_resources.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698