I have a simple \"Hello Android\" application on my computer (Eclipse environment), and I have built an APK file. How do I transfer the APK file to my Android phone for test
outside device,we can use :
adb install file.apk
or adb install -r file.apk
adb install [-l] [-r] [-s] [--algo --key --iv ]
- push this package file to the device and install it
('-l' means forward-lock the app)
('-r' means reinstall the app, keeping its data)
('-s' means install on SD card instead of internal storage)
('--algo', '--key', and '--iv' mean the file is encrypted already)
inside devices also, we can use:
pm install file.apk
or pm install -r file.apk
pm install: installs a package to the system. Options:
-l: install the package with FORWARD_LOCK.
-r: reinstall an exisiting app, keeping its data.
-t: allow test .apks to be installed.
-i: specify the installer package name.
-s: install package on sdcard.
-f: install package on internal flash.
-d: allow version code downgrade.