summaryrefslogtreecommitdiff
path: root/scripts/update_device.py
diff options
context:
space:
mode:
authorKelvin Zhang <zhangkelvin@google.com>2021-04-01 22:20:55 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2021-04-01 22:20:55 +0000
commitd4a81ab9739ca924b00ef23fd06be091f75b3d95 (patch)
treeda21194e80ed86c9ac7708f5738e736353105f19 /scripts/update_device.py
parent1da6b8d104039b9d959818953fb2c2c466b06dab (diff)
parentdf3a22e54bb1a8ef834c45b8c6853415125de7e6 (diff)
Add no postinstall option am: bec0f07516 am: 33c2435597 am: df3a22e54b
Original change: https://android-review.googlesource.com/c/platform/system/update_engine/+/1660742 Change-Id: I80bfc439cc92f13c771ec651748646c5eaa7961d
Diffstat (limited to 'scripts/update_device.py')
-rwxr-xr-xscripts/update_device.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/scripts/update_device.py b/scripts/update_device.py
index 074b91d6..b784b1bc 100755
--- a/scripts/update_device.py
+++ b/scripts/update_device.py
@@ -428,6 +428,8 @@ def main():
help='Update with the secondary payload in the package.')
parser.add_argument('--no-slot-switch', action='store_true',
help='Do not perform slot switch after the update.')
+ parser.add_argument('--no-postinstall', action='store_true',
+ help='Do not execute postinstall scripts after the update.')
parser.add_argument('--allocate_only', action='store_true',
help='Allocate space for this OTA, instead of actually \
applying the OTA.')
@@ -472,6 +474,8 @@ def main():
if args.no_slot_switch:
args.extra_headers += "\nSWITCH_SLOT_ON_REBOOT=0"
+ if args.no_postinstall:
+ args.extra_headers += "\nRUN_POST_INSTALL=0"
with zipfile.ZipFile(args.otafile) as zfp:
CARE_MAP_ENTRY_NAME = "care_map.pb"