Skip to content

Allow bypassing bundle-less apps such as Minecraft - #5

Merged
TW527E merged 1 commit into
mainfrom
fix/java-game-bypass
Oct 8, 2026
Merged

TW527E merged 1 commit into
mainfrom
fix/java-game-bypass

Conversation

@TW527E

@TW527E TW527E commented Oct 8, 2026

Copy link
Copy Markdown
Owner

Problem

Java games like Minecraft (launched from Prism Launcher or the official launcher) run as a bare java executable. macOS reports them with bundleIdentifier == nil, so ForegroundApplicationInfo returned nil and ShiftIME kept treating the previous app (e.g. Prism Launcher) as the foreground app. They could not be added to the bypass list from the menu bar, and the 「加入 App…」 panel only accepts .app bundles.

Fix

  • ForegroundApplicationInfo falls back to the executable path (e.g. …/PrismLauncher/java/java-runtime-epsilon/bin/java) when there is no bundle ID. The existing bypass sets, menu bar toggle and status checks work unchanged with this identifier.
  • The preferences app list truncates names in the middle so executable paths stay readable, and the bypass note tells users to add Java games from the menu bar while they run.

Testing

  • make verify passes: 43 checks plus the app smoke test.
  • Confirmed a running Minecraft process reports bundleIdentifier = nil and a non-nil executableURL.
  • Rendered the preferences window offscreen: the layout still fits and the path row displays as /Users/…/bin/java.
  • Not yet tried: adding Minecraft from the menu bar in the running app.

Limits

  • The 「加入 App…」 panel still cannot pick a bare executable; the menu bar is the only way to add one.
  • Excluding a java path also excludes other programs using the same Java runtime.
  • Minecraft is not auto-detected as a game.

🤖 Generated with Claude Code

Java games like Minecraft run as a bare `java` executable with no bundle
identifier, so ShiftIME never recognized them as the foreground app and
they could not be added to the bypass list. Fall back to the executable
path as the identifier and point users to the menu bar item for them.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Copilot AI balanced review requested due to automatic review settings October 8, 2026 13:18

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@TW527E
TW527E merged commit d3e8d70 into main Oct 8, 2026
3 checks passed
@TW527E
TW527E deleted the fix/java-game-bypass branch October 8, 2026 14:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants