Skip to content

Let users choose where Steam is installed - #30

Closed
LaganYT wants to merge 2 commits into
NotProtonNot:dev-1.1.0from
LaganYT:choose-steam-location
Closed

LaganYT wants to merge 2 commits into
NotProtonNot:dev-1.1.0from
LaganYT:choose-steam-location

Conversation

@LaganYT

@LaganYT LaganYT commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Closes #29. NotProton only looked for Steam at /Applications/Steam.app, so anyone running Steam from an external drive got "Steam not found" and couldn't install.

Summary

The Steam section gets a Location row with a Choose button, like the one CrossOver has. The chosen path is saved in user defaults, and everything that touches Steam already reads SupportPaths.Steam.app, so it all follows.

 SupportPaths.Steam.app
-  /Applications/Steam.app
+  saved "steamAppPath" ?? /Applications/Steam.app

 Status > Steam
+  Location   /Volumes/Games/Steam.app   [Choose…]
   NotProton  Not installed.             [Install]
chooseSteam
  picked app's bundle id must be com.valvesoftware.steam
  if NotProton is patched into the current Steam
    refuse: "Use Repair Steam to remove it first"
  save path (choosing /Applications/Steam.app clears the setting)
  refresh

The refusal is there because switching would otherwise leave the old copy patched, and Repair Steam and Remove Everything would no longer see it.

Repair Steam needed one fix. It swaps in Valve's bundle from ~/Library/Caches, and that swap can't cross drives. When Steam is on another volume, it now copies the bundle next to Steam first.

 SteamRepair.replace(app, staged)
+  if staged and app's folder are on different volumes
+    copy staged beside app, use the copy
   replaceItemAt(app, staged)

Evidence

Throwaway test (not committed, since it needs a second drive): put a fake Steam.app on an external SSD and a staged one in the temp dir, then call SteamRepair.replace.

  • Before: Cross-device link (POSIX 18), Steam left unchanged
  • After: passes, the new bundle is in place and no staging copy is left behind

swift test passes, except for 5 tests that need make app-payload staged locally and one locking test that times out under the parallel run but passes alone. Both fail the same way without this change.

Live test with a clean Valve copy of Steam at /Volumes/SSK-SSD/np-steam-test/Steam.app and the real /Applications/Steam.app (NotProton installed in it):

  • Choosing the SSD copy while /Applications was patched was refused with the Repair Steam hint.
  • Choosing CrossOver was refused as "not Steam".
  • After Repair Steam on /Applications, choosing the SSD copy worked. Install wrote DYLD_INSERT_LIBRARIES=/Volumes/SSK-SSD/np-steam-test/Steam.app/Contents/MacOS/notproton.dylib and the bundle still verified.
  • Steam launched from the SSD copy loaded the dylib from the SSD (lsof on steam_osx), and Zuma Deluxe launched through it.
  • Repair Steam with Steam still running stopped it and restored Valve's signed bundle (team MXGJJ98X76) on the SSD. No staging copy was left behind.
  • Choosing /Applications/Steam.app again cleared the saved setting, and Install put everything back.

The live test caught one bug, fixed in the second commit. The picker returns bundles with a trailing slash, so choosing /Applications/Steam.app saved /Applications/Steam.app/ instead of clearing the setting.

Merge Danger

Door: two-way

With the setting unset, behavior is the same as before. Reverting just stops reading the saved path.

Blast Radius: small

Only users who pick a custom location are affected. If their drive is unplugged, Steam shows as not found, and actions that lock Steam's folder fail with a "Could not lock" error until it's plugged back in.

Steam on an external drive was reported as not found. The Status page now has a Choose button for Steam's location, and Repair Steam copies Valve's bundle onto that drive before swapping it in, since the swap cannot cross drives.

Closes NotProtonNot#29
NSOpenPanel returns app bundles as directory URLs, so choosing /Applications/Steam.app saved it with a slash instead of clearing the setting, and Steam's stop patterns came out as Steam.app//.
@LaganYT
LaganYT marked this pull request as ready for review October 8, 2026 03:21
@NotProtonNot

Copy link
Copy Markdown
Owner

Thank you, merged as #142

@LaganYT
LaganYT deleted the choose-steam-location branch October 19, 2026 13:50
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