diff options
author | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2022-11-10 00:29:39 +0000 |
---|---|---|
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2022-11-10 00:29:39 +0000 |
commit | ae16afd5f1028521a6c46de0c79f0dff63beb4f5 (patch) | |
tree | ddd06a478601244d019bc60231f0fe33d9d3f3d1 | |
parent | 04403a1839fe7fc1e5ebf90211a13e5d9843764b (diff) | |
parent | 141675a123b699a86de0918d71719a43571ec905 (diff) | |
download | sdk-ae16afd5f1028521a6c46de0c79f0dff63beb4f5.tar.gz |
Snap for 9274385 from 141675a123b699a86de0918d71719a43571ec905 to tm-qpr2-release
Change-Id: I2f353dfffeb23a42353580142dc0d9fd54dfae8d
-rwxr-xr-x | update_prebuilts/update_prebuilts.py | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/update_prebuilts/update_prebuilts.py b/update_prebuilts/update_prebuilts.py index 741525fba..46d8e4483 100755 --- a/update_prebuilts/update_prebuilts.py +++ b/update_prebuilts/update_prebuilts.py @@ -29,6 +29,7 @@ androidx_dir = os.path.join(current_path, 'androidx') androidx_owners = os.path.join(androidx_dir, 'OWNERS') java_plugins_bp_path = os.path.join(androidx_dir, 'JavaPlugins.bp') test_mapping_file = os.path.join(androidx_dir, 'TEST_MAPPING') +compose_test_mapping_file = os.path.join(androidx_dir, 'm2repository/androidx/compose/TEST_MAPPING') gmaven_dir = os.path.join(current_path, 'gmaven') extras_dir = os.path.join(current_path, 'extras') buildtools_dir = 'tools' @@ -707,7 +708,13 @@ def update_androidx(target, build_id, local_file, include, exclude, beyond_corp) f.write('\nbuild = ["JavaPlugins.bp"]\n') # Keep OWNERs file, JavaPlugins.bp file, and TEST_MAPPING files untouched. - subprocess.check_call(['git', 'restore', androidx_owners, java_plugins_bp_path, test_mapping_file]) + files_to_restore = [androidx_owners, java_plugins_bp_path, test_mapping_file, + compose_test_mapping_file] + for file_to_restore in files_to_restore: + # Ignore any output or error - these files are not gauranteed to exist, but + # if they do, we want to restore them. + subprocess.call(['git', 'restore', file_to_restore], + stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) return True |