added comments and removed need to redownload
This commit is contained in:
parent
841cf43d59
commit
fc9557a42d
29
flash-it.sh
29
flash-it.sh
|
@ -112,19 +112,25 @@ select OPTION in "PinePhone device" "PineTab device" "Dont Be Evil devkit"; do
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
# Downloading images
|
# Check if already downloaded before downloading
|
||||||
echo -e "\e[1mDownloading images...\e[0m"
|
ls pinephone-rootfs.zip || {
|
||||||
WGET=$(wget_cmd)
|
# Downloading images
|
||||||
UBOOT_DOWNLOAD="https://gitlab.com/sailfishos-porters-ci/dont_be_evil-ci/-/jobs/artifacts/$BRANCH/download?job=$UBOOT_JOB"
|
echo -e "\e[1mDownloading images...\e[0m"
|
||||||
$WGET "${UBOOT_JOB}.zip" "${UBOOT_DOWNLOAD}" || {
|
WGET=$(wget_cmd)
|
||||||
echo >&2 "UBoot image download failed. Aborting."
|
UBOOT_DOWNLOAD="https://gitlab.com/sailfishos-porters-ci/dont_be_evil-ci/-/jobs/artifacts/$BRANCH/download?job=$UBOOT_JOB"
|
||||||
exit 2
|
$WGET "${UBOOT_JOB}.zip" "${UBOOT_DOWNLOAD}" || {
|
||||||
|
echo >&2 "UBoot image download failed. Aborting."
|
||||||
|
exit 2
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
ROOTFS_DOWNLOAD="https://gitlab.com/sailfishos-porters-ci/dont_be_evil-ci/-/jobs/artifacts/$BRANCH/download?job=$ROOTFS_JOB"
|
# Check if already downloaded before downloading
|
||||||
$WGET "${ROOTFS_JOB}.zip" "${ROOTFS_DOWNLOAD}" || {
|
ls u-boot.zip || {
|
||||||
echo >&2 "Root filesystem image download failed. Aborting."
|
ROOTFS_DOWNLOAD="https://gitlab.com/sailfishos-porters-ci/dont_be_evil-ci/-/jobs/artifacts/$BRANCH/download?job=$ROOTFS_JOB"
|
||||||
exit 2
|
$WGET "${ROOTFS_JOB}.zip" "${ROOTFS_DOWNLOAD}" || {
|
||||||
|
echo >&2 "Root filesystem image download failed. Aborting."
|
||||||
|
exit 2
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
# Select flash target
|
# Select flash target
|
||||||
|
@ -135,6 +141,7 @@ echo "Flashing image to: $DEVICE_NODE"
|
||||||
echo "WARNING: All data will be erased! You have been warned!"
|
echo "WARNING: All data will be erased! You have been warned!"
|
||||||
echo "Some commands require root permissions, you might be asked to enter your sudo password."
|
echo "Some commands require root permissions, you might be asked to enter your sudo password."
|
||||||
|
|
||||||
|
# use p1, p2 extentions instead of 1, 2 when using sd drives
|
||||||
if [[ $(echo $DEVICE_NODE | grep mmcblk) ]]; then
|
if [[ $(echo $DEVICE_NODE | grep mmcblk) ]]; then
|
||||||
BOOTPART="${DEVICE_NODE}p1"
|
BOOTPART="${DEVICE_NODE}p1"
|
||||||
DATAPART="${DEVICE_NODE}p2"
|
DATAPART="${DEVICE_NODE}p2"
|
||||||
|
|
Binary file not shown.
Loading…
Reference in New Issue