| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright 2014 The LUCI Authors. All rights reserved. | 2 # Copyright 2014 The LUCI Authors. All rights reserved. |
| 3 # Use of this source code is governed by the Apache v2.0 license that can be | 3 # Use of this source code is governed under the Apache License, Version 2.0 |
| 4 # found in the LICENSE file. | 4 # that can be found in the LICENSE file. |
| 5 | 5 |
| 6 """Compiles all *.proto files it finds into *_pb2.py.""" | 6 """Compiles all *.proto files it finds into *_pb2.py.""" |
| 7 | 7 |
| 8 import os | 8 import os |
| 9 import sys | 9 import sys |
| 10 | 10 |
| 11 APP_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) | 11 APP_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) |
| 12 sys.path.insert(0, os.path.join(APP_DIR, '..', 'components')) | 12 sys.path.insert(0, os.path.join(APP_DIR, '..', 'components')) |
| 13 sys.path.insert(0, os.path.join(APP_DIR, '..', 'third_party_local')) | 13 sys.path.insert(0, os.path.join(APP_DIR, '..', 'third_party_local')) |
| 14 | 14 |
| 15 from tools import compile_proto | 15 from tools import compile_proto |
| 16 | 16 |
| 17 | 17 |
| 18 if __name__ == '__main__': | 18 if __name__ == '__main__': |
| 19 sys.exit(compile_proto.main(sys.argv[1:], APP_DIR)) | 19 sys.exit(compile_proto.main(sys.argv[1:], APP_DIR)) |
| OLD | NEW |