Junji Watanabe | 607284d | 2023-04-20 03:14:52 +0000 | [diff] [blame] | 1 | #!/usr/bin/env python3 |
| 2 | # Copyright 2023 The Chromium Authors. All rights reserved. |
| 3 | # Use of this source code is governed by a BSD-style license that can be |
| 4 | # found in the LICENSE file. |
| 5 | """ |
| 6 | Developers invoke this script via autosiso or autosiso.bat to simply run |
| 7 | Siso builds. |
| 8 | """ |
| 9 | |
| 10 | import sys |
| 11 | |
| 12 | import reclient_helper |
| 13 | import siso |
| 14 | |
| 15 | |
| 16 | def main(argv): |
| 17 | with reclient_helper.build_context(argv) as ret_code: |
| 18 | if ret_code: |
| 19 | return ret_code |
| 20 | argv = [ |
| 21 | argv[0], |
| 22 | 'ninja', |
| 23 | # Do not authenticate when using Reproxy. |
| 24 | '-project=', |
| 25 | '-reapi_instance=', |
| 26 | ] + argv[1:] |
| 27 | return siso.main(argv) |
| 28 | |
| 29 | |
| 30 | if __name__ == '__main__': |
| 31 | try: |
| 32 | sys.exit(main(sys.argv)) |
| 33 | except KeyboardInterrupt: |
| 34 | sys.exit(1) |