Last active
August 29, 2015 14:05
-
-
Save sergiusens/17d11843b9605feeb6bf to your computer and use it in GitHub Desktop.
Install from recovery
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function install_from_recovery { | |
adb shell mkdir /mnt | |
adb shell mount /data/ubuntu.img /mnt | |
adb push "$1" /mnt/ | |
adb shell PATH=/bin:/usr/bin:/sbin:/usr/sbin chroot /mnt /usr/bin/dpkg -i "/$1" | |
adb shell "rm /mnt/$1" | |
adb shell sync | |
adb shell umount /mnt | |
adb shell rmdir /mnt | |
adb reboot | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment