diff options
author | Jean-Baptiste Queru <jbq@google.com> | 2012-06-26 08:35:16 -0700 |
---|---|---|
committer | Jean-Baptiste Queru <jbq@google.com> | 2012-06-26 08:35:16 -0700 |
commit | 9ceee5613b0474e97d0992550344ac02143206fa (patch) | |
tree | dc7f38c6065d08a8cc00e6f02ec4a61c38a5936e /generate-factory-images-common.sh | |
parent | 01bbc9753f32ee795965dda181c98b80ad6ef068 (diff) | |
download | device_common-9ceee5613b0474e97d0992550344ac02143206fa.tar.gz device_common-9ceee5613b0474e97d0992550344ac02143206fa.tar.bz2 device_common-9ceee5613b0474e97d0992550344ac02143206fa.zip |
Factory images: erase all partitions.
Change-Id: Iaa3248fabeaf976060c4c512c862cb88aae5c26d
Diffstat (limited to 'generate-factory-images-common.sh')
-rw-r--r-- | generate-factory-images-common.sh | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/generate-factory-images-common.sh b/generate-factory-images-common.sh index 5d06a09..a82e3d2 100644 --- a/generate-factory-images-common.sh +++ b/generate-factory-images-common.sh @@ -70,6 +70,18 @@ cat > tmp/$PRODUCT-$VERSION/flash-all.sh << EOF # See the License for the specific language governing permissions and # limitations under the License. +EOF +if test "$ERASEALL" = "true" +then +cat >> tmp/$PRODUCT-$VERSION/flash-all.sh << EOF +fastboot erase boot +fastboot erase cache +fastboot erase recovery +fastboot erase system +fastboot erase userdata +EOF +fi +cat >> tmp/$PRODUCT-$VERSION/flash-all.sh << EOF fastboot flash bootloader bootloader-$DEVICE-$BOOTLOADER.img fastboot reboot-bootloader sleep $SLEEPDURATION |