Forrest logo
tool overview
On this page you find all important commands for the CLI tool am. If the command you are looking for is missing please ask our AI.

am

The "am" command line tool, short for "Android Asset Packaging Tool," is a utility provided by the Android SDK. It is primarily used for building and packaging Android application resources. The tool enables developers to create the final distribution package (APK) by merging all the necessary assets, including compiled resources, libraries, and manifest files.

With "am," developers can package the application resources into a ZIP file format, which can be easily installed on an Android device or emulator. This makes it a crucial tool in the Android app development process. Additionally, the "am" tool supports various options like specifying the target device, launching activities, starting services, broadcasting intents, and much more. These options make it possible to interact with the installed Android application directly from the command line.

The "am" command line tool plays an important role in automated testing and debugging of Android applications as well, by allowing developers to send various intents or events to the application, which helps simulate user actions and behaviors. In addition, it provides features such as instrumenting with test code, profiling the application, and collecting performance data.

Furthermore, "am" can be used in conjunction with other Android tools like adb (Android Debug Bridge) to perform advanced tasks such as recording screen activity, capturing bug reports, managing permissions, or even creating custom scripts for application testing and deployment.

In summary, "am" is a powerful command line tool that facilitates the packaging, installation, testing, and debugging of Android applications, offering developers a convenient and efficient way to interact with their apps and streamline the development process.

List of commands for am:

  • am:tldr:3cbb7 am: Convert an intent to a URI.
    $ am to-uri -a ${android-intent-action-VIEW} -d ${tel:123}
    try on your machine
    explain this command
  • am:tldr:bdff6 am: Start an activity and pass [d]ata to it.
    $ am start -a ${android-intent-action-VIEW} -d ${tel:123}
    try on your machine
    explain this command
  • am:tldr:d5b7b am: Start an activity matching a specific action and [c]ategory.
    $ am start -a ${android-intent-action-MAIN} -c ${android-intent-category-HOME}
    try on your machine
    explain this command
  • am:tldr:eac24 am: Start a specific activity.
    $ am start -n ${com-android-settings--Settings}
    try on your machine
    explain this command
tool overview