diff --git a/flash_FP3_factory.sh b/flash_FP3_factory.sh index 59669b042fd426efa5e3abf6e1bdac96e6a61663..71c9b995137f9a9ab21237ae5a9840a83daac31f 100755 --- a/flash_FP3_factory.sh +++ b/flash_FP3_factory.sh @@ -41,10 +41,10 @@ find_device() { do serial_numbers= - for sn in $(${FASTBOOT_BIN} devices | grep fastboot | grep -oE '^[[:alnum:]]+') + for sn in $("${FASTBOOT_BIN}" devices | grep fastboot | grep -oE '^[[:alnum:]]+') do # Checking the product ID - PRODUCT_STRING=$(${FASTBOOT_BIN} -s "${sn}" getvar product 2>&1) + PRODUCT_STRING=$("${FASTBOOT_BIN}" -s "${sn}" getvar product 2>&1) # Add serial, if product matches if [[ ${PRODUCT_STRING} == *"${PRODUCT_ID}"* ]] || [[ ${PRODUCT_STRING} == *"${PRODUCT_ID_OLD}"* ]] then @@ -114,7 +114,7 @@ flash_device() { flash_image_or_abort "${sn}" userdata "${IMAGES_DIR}/userdata.img" fi - $FASTBOOT_BIN -s "${sn}" --set-active=a + "$FASTBOOT_BIN" -s "${sn}" --set-active=a echo "INFO: Locking bootloader" "${FASTBOOT_BIN}" -s "${sn}" oem lock @@ -134,7 +134,7 @@ flash_device() { # Arguments: flash_image_or_abort() { local retval=0 - $FASTBOOT_BIN -s "${1}" flash "${2}" "${3}" || retval=$? + "$FASTBOOT_BIN" -s "${1}" flash "${2}" "${3}" || retval=$? if [ "${retval}" -ne 0 ] then diff --git a/flash_FP4_factory.sh b/flash_FP4_factory.sh index 1a7cc1093281b4691ab318d4f74dc5943a8c44dc..fa35ef46f4929880ad02c2778040085732d591e6 100755 --- a/flash_FP4_factory.sh +++ b/flash_FP4_factory.sh @@ -37,10 +37,10 @@ find_device() { do serial_numbers= - for sn in $(${FASTBOOT_BIN} devices | grep fastboot | grep -oE '^[[:alnum:]]+') + for sn in $("${FASTBOOT_BIN}" devices | grep fastboot | grep -oE '^[[:alnum:]]+') do # Checking the product ID - PRODUCT_STRING=$(${FASTBOOT_BIN} -s "${sn}" getvar product 2>&1) + PRODUCT_STRING=$("${FASTBOOT_BIN}" -s "${sn}" getvar product 2>&1) # Add serial, if product matches if [[ ${PRODUCT_STRING} == *"${PRODUCT_ID}"* ]] || [[ ${PRODUCT_STRING} == *"${PRODUCT_ID_OLD}"* ]] then @@ -111,10 +111,10 @@ flash_device() { flash_image_ab_or_abort "${sn}" xbl_config "${IMAGES_DIR}/xbl_config.img" flash_image_ab_or_abort "${sn}" core_nhlos "${IMAGES_DIR}/core_nhlos.img" - $FASTBOOT_BIN -s "${sn}" erase userdata - $FASTBOOT_BIN -s "${sn}" erase metadata + "$FASTBOOT_BIN" -s "${sn}" erase userdata + "$FASTBOOT_BIN" -s "${sn}" erase metadata - $FASTBOOT_BIN -s "${sn}" --set-active=a + "$FASTBOOT_BIN" -s "${sn}" --set-active=a } @@ -122,7 +122,7 @@ flash_device() { # Arguments: flash_image_or_abort() { local retval=0 - $FASTBOOT_BIN -s "${1}" flash "${2}" "${3}" || retval=$? + "$FASTBOOT_BIN" -s "${1}" flash "${2}" "${3}" || retval=$? if [ "${retval}" -ne 0 ] then