Index: mojo/public/tools/dart_list_mojoms.py |
diff --git a/mojo/dart/embedder/tools/dart_list_generated_bindings.py b/mojo/public/tools/dart_list_mojoms.py |
similarity index 87% |
copy from mojo/dart/embedder/tools/dart_list_generated_bindings.py |
copy to mojo/public/tools/dart_list_mojoms.py |
index a630ad15ec3ddd5d1c9e7774877a6c823f5ac841..1ef886cfb60ac411fa1f4b6dc5746e6e1916bd97 100755 |
--- a/mojo/dart/embedder/tools/dart_list_generated_bindings.py |
+++ b/mojo/public/tools/dart_list_mojoms.py |
@@ -3,8 +3,7 @@ |
# Use of this source code is governed by a BSD-style license that can be |
# found in the LICENSE file. |
-# This script scans a directory tree for any .mojom files and outputs a list of |
-# .mojom.dart files. |
+# This script scans a directory tree for any .mojom files and outputs a list. |
import argparse |
import os |
@@ -27,16 +26,11 @@ def main(args): |
# Prefix to chop off output. |
root_prefix = os.path.abspath(args.relative_directory_root) |
for dirname, _, filenames in os.walk(source_directory): |
- # filter for .mojom.dart files. |
+ # filter for .mojom files. |
filenames = [f for f in filenames if f.endswith('.mojom')] |
for f in filenames: |
- # Ignore tests. |
- if dirname.endswith('tests'): |
- continue; |
path = os.path.abspath(os.path.join(dirname, f)) |
path = os.path.relpath(path, root_prefix) |
- # Append .dart. |
- path += '.dart' |
print(path) |
if __name__ == '__main__': |