| # Copyright (c) 2025, the R8 project authors. Please see the AUTHORS file |
| # for details. All rights reserved. Use of this source code is governed by a |
| # BSD-style license that can be found in the LICENSE file. |
| parser = argparse.ArgumentParser(description='Update androidx keep annotations') |
| parser.add_argument('--androidx', |
| help='Path to the androidx checkout') |
| return parser.parse_args() |
| source_dir = os.path.join( |
| for root, dirnames, filenames in os.walk(source_dir): |
| print('Unexpected subdirectory under {source_dir}.' |
| .format(source_dir=source_dir)) |
| print('Unexpected subdirectories under {dirnames}.' |
| .format(dirnames=dirnames)) |
| for filename in filenames: |
| if not filename.endswith(KOTLIN_EXTENSION): |
| print('Unexpected non Kotlin file {filename}.' |
| .format(filename=os.path.join(root, filename))) |
| os.path.join(root, filename), |
| os.path.join(dest_dir, filename)) |
| if __name__ == '__main__': |