android-source-search
Installation
SKILL.md
Android Source Search
Two source trees, two access strategies. AOSP lives on android.googlesource.com (Gitiles); AndroidX lives on GitHub. cs.android.com blocks automated fetching — it's a human-browse JS SPA only (never WebFetch it).
Preferred: the android-sources MCP
If mcp__android-sources__* tools are available, always prefer them over WebFetch/gh — local source, sub-10ms lookups:
| Goal | MCP tool |
|---|---|
| Find a class by name/pattern | search_classes (glob, e.g. *ViewModel*) |
| Read full class / a method / its members | lookup_class / lookup_method / list_class_members |
| Class hierarchy | get_class_hierarchy |
| Search text/regex across sources | search_in_source |
| List AndroidX artifact versions | list_available_versions |
| Definition / references / type info (LSP) | goto_definition / find_references / get_type_info |
Fall back to the WebFetch/gh strategies below only when the MCP tools aren't available.