Mole icon indicating copy to clipboard operation
Mole copied to clipboard

[BUG] Descriptive titles for apps having same names and different versions

Open hamsternik opened this issue 8 months ago • 4 comments

Describe the bug

After running mole CLI, then select 'Uninstall' and get the list of all installed apps, there are cases e.g. with Xcode that displays the same "Xcode" name for all of apps. Each Xcode app has it's own name based on the version. Attached 2 screen shots to show the difference how app names are displayed in the system and how mole shows them.

what I see in Finder:

Image

what I see in mole:

Image

Steps to reproduce

  1. Run command: mo uninstall
  2. see the apps list, tap 's' to sort alphabetically
  3. no difference in names between apps

Expected behavior

Complete name including app's version to distinguish between them.

Debug logs

Please run the command with --debug flag and paste the output here:

mo uninstall --debug

Output from ~/.config/mole/mole_debug_session.log (END)

----------------------------------------------------------------------
Mole Debug Session, 2026-03-21 13:50:42
----------------------------------------------------------------------
User: hamsternik
Hostname: Mac.lan
Architecture: arm64
Kernel: 24.6.0
macOS: 15.7.4, 24G517
Shell: /opt/homebrew/bin/fish, xterm-256color
Sudo Access: Required
----------------------------------------------------------------------

Additional context

Add any other context about the problem here, such as screenshots or related issues.

hamsternik avatar Mar 21 '26 13:03 hamsternik

Thanks for the report — I’ve opened a fix PR for this.

What was happening

mo uninstall could prefer metadata display names (e.g. Xcode) over the bundle filename, so multiple installed versions looked identical in the selection list.

What the fix does

When metadata is generic, Mole now keeps the versioned bundle name from the app filename (for example Xcode 15.x vs Xcode 16.x) so entries are distinguishable.

Validation

  • bash -n bin/uninstall.sh
  • ./scripts/check.sh --no-format
  • Manual check in ./bin/uninstall.sh list + alphabetical sort (s)

PR: https://github.com/tw93/Mole/pull/617

Victorola-coder avatar Mar 21 '26 15:03 Victorola-coder

Thanks for such a quick response and the fix all together.

I just have checked with your PR edits – works fine for me.

Image

*Waiting when the fix will be merged into (main) branch from the fork.

hamsternik avatar Mar 21 '26 19:03 hamsternik

Sure, Glad to help.

Victorola-coder avatar Mar 21 '26 21:03 Victorola-coder

@hamsternik I pushed the fix directly to main in commit 0c71ee9.

Mole now keeps versioned bundle names when metadata collapses multiple installs into the same generic title, and I added a BATS regression test for that path. Please update to the latest main and re-check the uninstall list.

tw93 avatar Mar 22 '26 06:03 tw93