Phase 3: App Manager metadata, label resolution, GUI/CLI detail views - #2
Open
arena-ai-coding-agent[bot] wants to merge 1 commit into
Open
Phase 3: App Manager metadata, label resolution, GUI/CLI detail views#2arena-ai-coding-agent[bot] wants to merge 1 commit into
arena-ai-coding-agent[bot] wants to merge 1 commit into
Conversation
…iews Shared core (internal/adb): - Expanded Package model with UID, Min/Target SDK, Enabled, SplitCodePaths. - Added DisplayTitle()/VersionSummary() presenters and FormatMillis(). - Added resolveLabels() using two best-effort device-side passes: (1) batched per-package dumpsys grep for applicationLabel=; (2) batched 'cmd package resolve-activity' fallback for launcher apps. Resource IDs (0x7f...) and numeric noise are filtered; labels are never fabricated, falling back to package name when unresolvable. - enrichFromDumpsys now parses minSdk=/targetSdk=, splitCodePaths=[...], uid=/userId=, and User 0: installed=false. - PackageInfo() convenience added on Manager for detail views. GUI: - Two-line list items showing bold label (primary), monospace package name (secondary), and version tag on the right. - New Details screen with Back button, bold application name, Form rows for Type/Version/Enabled/Installer/APK path/Split APKs/UID/SDKs/timestamps, and inline Launch/Force Stop/Uninstall actions reusing shared-core ops with existing confirmation dialogs. Detail view refreshes with app-list refreshes and auto-closes when the package disappears. - Search continues to match label and package name; existing Install APK… and Mirror functionality preserved. CLI: - New 'info [<pkg>|n]' command (aliases show/details) in REPL and non- interactive modes, mirroring GUI metadata. - REPL caches last apps/search listing; launch/stop/uninstall/info accept a numeric index with interactive prompt when no arg given. - 'apps' output includes the resolved label. - Existing scriptable subcommand syntax preserved. Note: CI/release workflow changes (to add vet/test for the new internal/ module) are intentionally excluded from this commit because the CI bot lacks workflows permission; they should be applied in a follow-up by a maintainer with workflows:write permission. Co-authored-by: arena-agent <297053741+arena-agent@users.noreply.github.com>
Deploying adbpure with
|
| Latest commit: |
a336b90
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://cbdcd540.adbpure.pages.dev |
| Branch Preview URL: | https://arena-019feb0a-adbpureflow.adbpure.pages.dev |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Phase 3 builds on the shared
internal/adbcore introduced in Phase 2 (this PR also lands the Phase 2 shared-core / CI-release / CLI+GUI rewrite that was pending on this branch) and focuses on making installed applications understandable and inspectable.Shared core (
internal/adb)Packagemodel withUID,MinSdk,TargetSdk,Enabled, andSplitCodePaths.Package.DisplayTitle(),Package.VersionSummary(), andadb.FormatMillis().enrichFromDumpsysnow parsesminSdk=/targetSdk=,splitCodePaths=[…],uid=/userId=, andUser 0: installed=falsestate.resolveLabels()runs two best-effort, device-side-only label passes (noaapt, no APK pulls):dumpsys package <pkg> | grep 'applicationLabel=|…'over packages whose dumpsysapplicationLabel=is a resource ID.cmd package resolve-activity -c android.intent.category.LAUNCHER <pkg> | grep '^label=|…'fallback for launcher apps.0x7f…) and numeric noise are filtered out; labels are never fabricated. Callers fall back toPackage.NameviaDisplayTitle().Manager.PackageInfo()convenience for the new detail views.GUI
widget.Formshowing Type, Version, Enabled, Installer, APK path, Split APKs, UID, Target SDK, Min SDK, First installed, Last updated. Inline Launch / Force Stop / Uninstall buttons reuse the shared core; confirmation dialogs are retained for destructive actions.CLI
info [<pkg>|n]command (aliases:show,details) in both REPL and non-interactive modes, rendering the same structured metadata as the GUI (em-dashes for unknown fields).apps/searchlisting;launch/stop/uninstall/infoaccept a numeric index or prompt interactively when no argument is given.appsoutput now includes the resolved label. All existing scriptable subcommand syntax is preserved.CI/CD
.github/workflows/release.yml,.github/scripts/*, PR template, RELEASING/CONTRIBUTING docs, version linker-stamping for CLI/GUI) ships as part of this branch.go vet/go testcoverage for the newinternal/module is intentionally not included in this PR. The GitHub App token used here lacksworkflowspermission and GitHub rejects pushes that modify workflow files without it; a maintainer withworkflows:writeshould make the following small follow-up change to.github/workflows/ci.yml:internal/go.modto eachcache-dependency-path,gofmt -l CLI GUI internal,cd internal && go vet ./…andcd internal && go test -v -race ./…steps.release.yml) already referencesinternal/go.modvia the module replace directives; no release-pipeline behavior is broken.Validation
cmd packageoutputs):User 0: installed=falseparsing.application-label:'…',nonLocalizedLabel=…, numeric noise, no label lines).looksLikeResourceID,looksNumeric,parseBracketedList,VersionSummary,DisplayTitle,FormatMillis.dashIfEmpty,yesNo,i64toa, stdout-capturedprintPackageInfo..gofile (Go toolchain is not available in this sandbox — CI on GitHub Actions will rungofmt,go vet, andgo test -raceacross modules and platforms once approved).-ldflags="-X main.version=${VERSION}"version stamping, and the multi-platform build matrix/artifact naming are preserved.Breaking Changes
devices,apps [-u] [serial],install,launch,stop,uninstall,mirror) is unchanged; REPL numeric selection is additive.Packageare within the internalinternal/adbpackage and do not affect external consumers.Notes
aapt).