• Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb wit

    From Arno Welzel@3:633/10 to All on Friday, October 09, 2026 09:12:50
    Subject: Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb with Android

    In the following examples APPLICATION is the full identifier of an
    application package.

    To find out this identifier, go to the app list in Android, open the application information of the app and scroll down to the end of the
    list. There you should find the identifier. If you have a vendor
    specific UI (Xiaomi, Samsung etc.) it may look different. In this case,
    check Google Play online in a browser. The application identifier is
    part of the URL after the "id=" parameter like this:

    <https://play.google.com/store/apps/details?id=com.google.android.apps.messaging>

    For example Google Messages is com.google.android.apps.messaging and the
    ADB command to disable this for user 0 would be:

    adb shell pm disable-user --user 0 com.google.android.apps.messaging

    The identifier is the "reverse" domain notation intruced by Java, so
    instead of "google.com" at the end as the owner of the app it is
    "com.google" at the beginning.


    List of ADB commands to modify apps:


    Disable the app for user 0:

    adb shell pm disable-user --user 0 APPLICATION

    Note: the app will still be visible as installed app for this user and
    can be re-enabled. Using this command may work even when disabling the
    app within the Android UI is note possible.


    Re-enable an app that was disabled for user 0:

    adb shell pm enable --user 0 APPLICATION


    Force-stop an app:

    adb shell am force-stop APPLICATION


    Uninstall the app for user 0:

    adb shell pm uninstall --user 0 APPLICATION

    Note: if the app is preinstalled system app it may still be present in
    the file system and will only be made unavailable for user 0. It can be restored if neccessary.


    Restore a system/preinstalled app previously uninstalled for user 0:

    adb shell cmd package install-existing --user 0 APPLICATION



    --
    Arno Welzel
    https://arnowelzel.de

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Arno Welzel@3:633/10 to All on Friday, October 09, 2026 09:15:13
    Subject: Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb with Android

    ADB commands to copy files:


    Copy a file from a device to the computer:

    adb pull "PATH_ON_DEVICE" "PATH_ON_COMPUTER"


    Copy a file from the computer to the device:

    adb push "PATH_ON_COMPUTER" "PATH_ON_DEVICE"


    --
    Arno Welzel
    https://arnowelzel.de

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Siard@3:633/10 to All on Friday, October 09, 2026 10:30:31
    Subject: Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb with Android

    On Thu, 8 Oct 2026 15:46 -0700, Maria Sophia wrote:
    So that all benefit, this thread is opened to allow others to post random useful adb examples, where the goal is a usable list of useful examples.

    Do you know this one? <https://cheat.sh/adb>

    More about cheat.sh:
    <https://www.linuxlinks.com/excellent-utilities-cheat-sh-community-driven-cheat-sheet/>

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Frank Slootweg@3:633/10 to All on Friday, October 09, 2026 10:20:37
    Subject: Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb with Android

    Arno Welzel <usenet@arnowelzel.de> wrote:
    In the following examples APPLICATION is the full identifier of an application package.

    To find out this identifier, go to the app list in Android, open the application information of the app and scroll down to the end of the
    list. There you should find the identifier. If you have a vendor
    specific UI (Xiaomi, Samsung etc.) it may look different. In this case,
    check Google Play online in a browser. The application identifier is
    part of the URL after the "id=" parameter like this:

    <https://play.google.com/store/apps/details?id=com.google.android.apps.messaging>

    Please note that Samsung (and other?) devices sadly do *not* show the
    'id=' identifier in the 'App info' page of an app.

    For example for the (Google) 'Messages' app, it only mentions the
    'Version' (which says ...phone_samsung_dynamic). Same for other apps,
    such as (Google) 'Maps' (but that has no Samsung specific tag in
    'Version').

    As the app-private storage areas (/Android/data, media and obb) are
    not accessible for normal file managers, one can also not find the 'id=' identifier that way.

    So for most Samsung users, they have to search the Google Play website
    and hope they find the app(s) they have, and if so, lookup their 'id=' identifier in te URL of the Google Play entry.

    Alternatively, some - but not all - APK 'downloader's, show the 'id=' identifier. For example, I use (amongst others) the (now apparently
    defunct) 'Kanade' APK downloader, which indeed identifies the (Google)
    messages app as com.google.android.apps.messaging.

    [...]

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Don@3:633/10 to All on Friday, October 09, 2026 11:22:58
    Subject: Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb with Android

    On 10/8/26 16:46, Maria Sophia wrote:
    So that all benefit, this thread is opened to allow others to post random useful adb examples, where the goal is a usable list of useful examples.

    This recipe clones Contacts, Calls, SMS, and Photos from a source
    android with device serial R5C11111111 to a target android with device
    serial R5C22222222.

    Pull and Push Contacts

    cd ~/contacts
    adb -s R5C11111111 pull /sdcard/Download/Contacts.vcf

    cd ~/contacts
    adb -s R5C22222222 push Contacts.vcf /sdcard/Download/Contacts.vcf
    * open Contacts on new phone and import Contacts.vcf

    * Install SMS Backup & Restore
    cd ~/SMS_Backup_Restore_APK
    adb -s R5C22222222 install SMSBackupRestore-freeProductionRelease-10.26.010.apk

    * Pull and Push SMS
    *
    * SMS Backup & Restore > Advanced Options > Dates off > Backup
    * calls.xml and sms.xml
    cd ~/sms
    adb -s R5C11111111 pull /sdcard/Documents/calls.xml
    adb -s R5C11111111 pull /sdcard/Documents/sms.xml

    cd ~/sms
    adb -s R5C22222222 push calls.xml /sdcard/Documents/
    adb -s R5C22222222 push sms.xml /sdcard/Documents/

    * Use SMS Backup & Restore to restore from sms_backup.txt
    * More Options > Settings > Backup Location Settings > Save local copy
    * Set SMS Backup & Restore as default SMS App

    * Pull photos:
    cd ~/photos
    adb -s R5C11111111 pull /storage/sdcard0/DCIM

    * Push photos:
    adb -s R5C22222222 push DCIM /storage/self/primary

    --
    73, Don, WD7Q veritas _|_
    liberabit | https://www.qsl.net/wd7q vos |


    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Nuno Silva@3:633/10 to All on Friday, October 09, 2026 12:37:55
    Subject: Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb with Android

    On 2026-10-09, Frank Slootweg wrote:

    Arno Welzel <usenet@arnowelzel.de> wrote:
    In the following examples APPLICATION is the full identifier of an
    application package.

    To find out this identifier, go to the app list in Android, open the
    application information of the app and scroll down to the end of the
    list. There you should find the identifier. If you have a vendor
    specific UI (Xiaomi, Samsung etc.) it may look different. In this case,
    check Google Play online in a browser. The application identifier is
    part of the URL after the "id=" parameter like this:

    <https://play.google.com/store/apps/details?id=com.google.android.apps.messaging>

    Please note that Samsung (and other?) devices sadly do *not* show the
    'id=' identifier in the 'App info' page of an app.

    For example for the (Google) 'Messages' app, it only mentions the
    'Version' (which says ...phone_samsung_dynamic). Same for other apps,
    such as (Google) 'Maps' (but that has no Samsung specific tag in
    'Version').

    As the app-private storage areas (/Android/data, media and obb) are
    not accessible for normal file managers, one can also not find the 'id=' identifier that way.

    So for most Samsung users, they have to search the Google Play website
    and hope they find the app(s) they have, and if so, lookup their 'id=' identifier in te URL of the Google Play entry.

    Alternatively, some - but not all - APK 'downloader's, show the 'id=' identifier. For example, I use (amongst others) the (now apparently
    defunct) 'Kanade' APK downloader, which indeed identifies the (Google) messages app as com.google.android.apps.messaging.

    [...]

    It sounds silly to me that there's such an effort to hide identifiers,
    even when looking things up sometimes the instructions are "search for [presentation name of app]", which just reeks of lack of precision and
    of being abusable, I think even F-Droid doesn't make it easy to operate
    based on the actual application ID. IIRC it can be searched but won't
    show up in the program entry page, or was it in the list of the search results...

    --
    Nuno Silva

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Jeff Layman@3:633/10 to All on Friday, October 09, 2026 14:59:46
    Subject: Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb with Android

    On 09/10/2026 08:12, Arno Welzel wrote:
    In the following examples APPLICATION is the full identifier of an application package.

    To find out this identifier, go to the app list in Android, open the application information of the app and scroll down to the end of the
    list. There you should find the identifier. If you have a vendor
    specific UI (Xiaomi, Samsung etc.) it may look different. In this case,
    check Google Play online in a browser. The application identifier is
    part of the URL after the "id=" parameter like this:

    <https://play.google.com/store/apps/details?id=com.google.android.apps.messaging>

    For example Google Messages is com.google.android.apps.messaging and the
    ADB command to disable this for user 0 would be:

    adb shell pm disable-user --user 0 com.google.android.apps.messaging

    Or you could use the Muntashirakon App Manager. Putting "messages" in
    the search box results in:

    Messages
    com.google.android.apps.messaging

    Just entering f- (for F-Droid) results in:

    F-Droid
    org.fdroid.fdroid

    etc.

    --
    Jeff

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Jeff Layman@3:633/10 to All on Saturday, October 10, 2026 08:10:56
    Subject: Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb with Android

    On 09/10/2026 20:30, Maria Sophia wrote:
    Jeff Layman wrote:
    Or you could use the Muntashirakon App Manager. Putting "messages" in
    the search box results in:

    Messages
    com.google.android.apps.messaging

    Hi Jeff,

    I think I turned you on to Muntashirakon, didn't I?
    If so, I'm glad you enjoy it.

    It's very useful and I haven't even scratched the surface of what it can
    do - as per the current thread, for instance. It's also very easy to copy'n'paste the correct package name into the adb command.
    Agree the package name (i.e., the unique identifier) is critical when using adb commands & agree that Muntashirakon App Manager is the best GUI.
    <https://github.com/MuntashirAkon/AppManager> (apk)
    <https://muntashir.dev/AppManager/en/> (doc)

    Also agree the damn Samsung GUI is very different for no good reason
    from the stock Android experience that, oh, say, a Pixel affords us.

    Another way is to use adb to list all the package names on your system.
    adb shell pm list packages

    BTW, you can past your results into an LLM/AI and ask it to be brutally honest of what it thinks the user is who owns those apps on their phone.

    Take a look at this, based only on a list of package names on my phone:
    <https://i.postimg.cc/tCzzQNKT/Clipboard-10-09-2026-01.jpg>

    (very big snip)

    Out of interest, do the different LLM/AIs come up with the same answer?

    Here are other related package listing commands for adb:
    # List all packages on the device:
    adb shell pm list packages

    # List only third-party (user-installed) apps:
    adb shell pm list packages -3

    # List only system apps:
    adb shell pm list packages -s

    # List only enabled apps:
    adb shell pm list packages -e

    # List only disabled apps:
    adb shell pm list packages -d

    # Filter for a specific keyword (Case-insensitive):
    adb shell pm list packages | grep -i "google"

    # Count how many total packages are installed:
    adb shell pm list packages | wc -l

    # List packages that request a specific permission:
    adb shell pm list packages -g android.permission.CAMERA
    (Replace CAMERA with any permission string, such as
    ACCESS_FINE_LOCATION or READ_CONTACTS, etc.)

    # Show the APK file path alongside the package name:
    adb shell pm list packages -f

    # Show the UID (User ID) assigned to each package:
    adb shell pm list packages -U

    # Show installer source (who installed the app):
    adb shell pm list packages -i

    # Export a clean, un-prefixed list of just package names to a text file:
    adb shell pm list packages | sed 's/package://g' > installed_apps.txt

    I think that the Muntashirakon app manager can do most of those on its
    own, without recourse to adb.

    --
    Jeff

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From croy@3:633/10 to All on Friday, October 23, 2026 16:58:07
    Subject: Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb with Android

    On Fri, 23 Oct 2026 17:49:12 -0400, Maria Sophia <mariasophia@comprehension.com> wrote:

    I'm looking up commands to help clean out my internal 64GB sd card ('cuz I >gave my wife my 128GB sdcard and now I'm out of space) so these may help.

    "Internal 64GB sd card"? I'm not familiar with such. What is it?

    --
    croy

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Carlos E. R.@3:633/10 to All on Sunday, November 01, 2026 13:23:30
    Subject: Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb with Android

    On 2026-10-31 19:06, Stefan Ram wrote:
    Maria Sophia <mariasophia@comprehension.com> wrote or quoted:
    If someone else would run the adb commands to prove that, it would help.
    Or, if someone could show screenshots like I did, showing FF there.

    I told the chatbot my ideads for a little Halloween ADB story,
    and he wrote the actual wording for me!

    The rain outside the neon-lit shop window didn't fall;
    it seemed to dissolve into the heavy, charcoal fog of All
    Hallows' Eve. Inside, the shop smelled faintly of ozone and
    old parchment.

    ...

    Before Elena could even find the words to yell at him, she
    found herself back out on the chilly, fog-slicked sidewalk,
    the shop door locking firmly behind her with the soft chime of
    a digital bell.

    Heh :-)

    --
    Cheers,
    Carlos E.R.
    ES??, EU??.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Carlos E. R.@3:633/10 to All on Tuesday, November 03, 2026 18:01:48
    Subject: Re: FAQ: PSA: Tutorial: Walk-Thru etc. Random examples of using adb with Android

    On 2026-11-01 15:07, Maria Sophia wrote:
    Carlos E. R. wrote:
    Heh :-)

    I get it that for some, Usenet is for their childish amusement,
    but I'm trying to help people by providing useful adb examples.

    To further add value to this thread which proves how useful adb is
    for the average Android user, below is a post from moments ago which
    shows how to install software on the phone over Wi-Fi using adb
    without even knowing where the phone happens to be inside the home.

    Newsgroups: alt.comp.software.firefox
    Subject: Re: Android Firefox does NOT show up in my WhatsApp PDF attachment OpenWith sheet
    Date: Sun, 1 Nov 2026 10:01:44 -0400
    Message-ID: <11c7go7$2hik$1@nnrp.usenet.blueworldhosting.com>

    Arlen, repeating a post is noise and waste of our time, too.

    ...

    --
    Cheers,
    Carlos E.R.
    ES??, EU??.

    --- PyGate Linux v1.5.19
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)