Skip to content

Add maui android info environment summary command #129

@rmarinho

Description

@rmarinho

Summary

Add a maui android info command that displays a comprehensive summary of the current Android development environment — SDK path, JDK path/version, installed API levels, key tool paths, and license status.

Background

Google's android CLI provides:

android info    # Display the path to the default Android SDK used

Our CLI has maui android sdk check and maui android jdk check as separate health-check commands, and maui doctor --platform android for full diagnostics. But there is no single "show me the effective environment" command that answers: What SDK is MAUI using? What JDK? What API levels are installed? Where are the tools?

Use Cases

  1. Environment debugging: When something goes wrong, the first question is always "what SDK/JDK am I using?" A single maui android info command provides the answer instead of requiring multiple commands.
  2. Agent context: AI agents managing Android environments need a compact summary of the current state to make informed decisions about what to install, update, or configure.
  3. Documentation & support: When filing bug reports or asking for help, maui android info output provides all the context a support engineer needs in one paste.
  4. Verifying --sdk override: After using the proposed global --sdk flag (Add global --sdk path override for all Android commands #125), maui android --sdk /path info confirms which SDK is actually being used.

Proposed CLI Surface

maui android info           # Full environment summary
maui android info --json    # Machine-readable JSON

Text Output Example

Android Development Environment
  SDK Path:        /Users/dev/Library/Android/sdk (source: ANDROID_HOME)
  JDK Path:        /Users/dev/.maui/jdk/21 (OpenJDK 21.0.2)
  License Status:  ✓ All accepted

  Installed API Levels:
    Android 35 (API 35) — platform + build-tools 35.0.0 + system-image (google_apis/arm64-v8a)
    Android 34 (API 34) — platform + build-tools 34.0.0

  Tools:
    sdkmanager:  /Users/dev/Library/Android/sdk/cmdline-tools/13.0/bin/sdkmanager
    avdmanager:  /Users/dev/Library/Android/sdk/cmdline-tools/13.0/bin/avdmanager
    adb:         /Users/dev/Library/Android/sdk/platform-tools/adb
    emulator:    /Users/dev/Library/Android/sdk/emulator/emulator

JSON Output

{
  "sdkPath": "/Users/dev/Library/Android/sdk",
  "sdkPathSource": "ANDROID_HOME",
  "jdkPath": "/Users/dev/.maui/jdk/21",
  "jdkVersion": "21.0.2",
  "licensesAccepted": true,
  "requiresElevation": false,
  "installedApiLevels": [
    { "api": 35, "platform": true, "buildTools": "35.0.0", "systemImages": ["google_apis/arm64-v8a"] },
    { "api": 34, "platform": true, "buildTools": "34.0.0", "systemImages": [] }
  ],
  "tools": {
    "sdkmanager": "/Users/dev/.../sdkmanager",
    "avdmanager": "/Users/dev/.../avdmanager",
    "adb": "/Users/dev/.../adb",
    "emulator": "/Users/dev/.../emulator"
  }
}

Implementation Notes

  • Aggregates data from IAndroidProvider (SDK path, health), IJdkManager (JDK path/version), SdkManager (tool paths, packages), and license status
  • Groups installed packages by API level for the human-readable summary
  • Respects the proposed --sdk override (Add global --sdk path override for all Android commands #125) when available

References

Metadata

Metadata

Labels

enhancementNew feature or request

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions