- if [ -z "$target" ];
- then
- echo "Please set target"
- exit
- fi
- echo "Creating /mnt/tmp directory on $target"
- ssh root@$target "mkdir -p /mnt/tmp/; mount /dev/mmcblk1p1 /mnt/tmp;"
- echo "Copying files to $target"
- scp imx6y2c-em500-512m-emmc.Rev.C.dtb root@$target:/mnt/tmp/
- scp zImage root@$target:/mnt/tmp/
- echo "Mount & Unmount"
- ssh root@$target "sync; umount /mnt/tmp; rmdir /mnt/tmp; reboot;"
|