Hovatek Forum MOBILE Android [Tutorial] How to install apks and push files to Android using ADB
Try our Online TWRP Builder..its free!
Can't login? Please, reset your password.


[Tutorial] How to install apks and push files to Android using ADB

[Tutorial] How to install apks and push files to Android using ADB

hovatek
hovatek
hovatek
Administrator
49,570
11-10-2014, 11:51 AM
#1



Here's a guide on installing and pushing files to an Android phone using Android Debug Bridge (ADB). This would come in handy when you're having launcher issues like "error com.android.launcher stopped working" (recall you cant use your phone without a functional launcher) or you accidentally deleted a core app or file(s) which has caused your phone to malfunction.

Requirement

  • Setup ADB
  • PC
  • App / file to be sent to the phone
  • USB cord
  • USB Debugging enabled phone

Installing an application using ADB (where app name is hovatek.apk)


  1. Launch ADB and type the following command then press Enter

    Code:

    adb devices

  2. ADB should detect connected devices (ensure only one is connected at a time to avoid confusion)
  3. Copy the app to the same folder as ADB (adb.exe)

    Note: to change installation location (where the app should be installed) to SD card, use the code below

    Code:

    adb shell pm set-install-location 2

    Install location values are:

    0: Auto—Let system decide the best location
    1: Internal—install on internal device storage
    2: External—install on external media


  4. Go back to the ADB command prompt and type the following command then press Enter
    Code:

    adb install hovatek.apk

Uninstalling an application using ADB (where package name is com.android.hovatek)


  1. Type the code below in ADB then press Enter

    Code:

    adb uninstall com.android.hovatek

    This will uninstall hovatek


    Pushing a file from PC to your phone (a file named file.txt to a folder named hovatek in SD card)

  2. Launch ADB and type the following command then press Enter

    Code:

    adb devices

  3. ADB should detect connected devices (ensure only one is connected at a time to avoid confusion)
  4. Copy the file to the same folder as ADB (adb.exe)
  5. In ADB command prompt, type the code below then press Enter

    Code:

    adb push file.txt sdcard/hovatek


    Pulling a file from phone to your PC (a file named file.txt from a folder named hovatek in SD card)

  6. In ADB command prompt, type the code below then press Enter

    Code:

    adb pull /sdcard/hovatek/file.txt


    Pulling a folder from your phone to your PC (a folder named fonts in system)

    Code:

    adb pull /system/fonts fonts/


    Note: You can push or pull using other directories on the phone e.g /system ,  /data etc

    How to set /change file permissions

    To set / change file permission, run the code below

    Code:

    adb devices
    adb shell
    su
    cd system
    chmod 644 filename.apk

    Replace
  7. system with the file path e.g system/apps
  8. 644 with the file permission
  9. filename.apk with the complete file or folder name
This post was last modified: 16-06-2018, 11:17 AM by hovatek.

Note!
We have a reply schedule for Free Support. Please upgrade to Private Support if you can't wait.
Users browsing this thread:
 1 Guest(s)
Users browsing this thread:
 1 Guest(s)
YtWhTl
live chat
whatsapp telegram instagram