liquidx / webviewscreensaver

Mac OS X Screen Saver powered by a Web View
Apache License 2.0
1.17k stars 138 forks source link

defaults command doesn't work under Catalina on M1 Mac #74

Closed virtzilla closed 6 months ago

virtzilla commented 2 years ago

The defaults command listed on the docs, i.e. defaults -currentHost read WebViewScreensaver does not return any results on an M1 mac mini running Catalina (12.5.1 21G83):

defaults -currentHost read WebViewScreensaver

2022-08-19 23:28:30.605 defaults[15777:410369]
Domain WebViewScreensaver does not exist

there is no separate file to search against under **~/Library/Preferences/ByHost/WebViewScreenSaver.*** to run the PlistBuddy command provided against.

If I do a defaults -currentHost read or defaults -currentHost find Web I do see the WebViewScreensaver preferences listed in there ("Found 2 keys in domain 'WebViewScreenSaver': {...".

Not sure if this is a WebViewScreensaver issue or an issue with the defaults system and changes with it under Catalina.

BenjiThatFoxGuy commented 1 year ago

M1 doesn't support Catalina, are you sure you're on an M1 Mac Mini?

xmddmx commented 1 year ago

For 10.15 Catalina and higher, screensavers are run in a sandboxed process called legacyScreenSaver.

You can edit the settings inside the sandbox like this:

plutil -replace KEY -string "VALUE" /Users/[username]/Library/Containers/com.apple.ScreenSaver.Engine.legacyScreenSaver/Data/Library/Preferences/net.liquidx.WebViewScreenSaver

Note: if you happen to be running an Intel only build on an Apple Silicon system, the sandbox is slightly different due to Rosetta translation:

plutil -replace KEY -string "VALUE" /Users/[username]/Library/Containers/com.apple.ScreenSaver.Engine.legacyScreenSaver-x86_64/Data/Library/Preferences/net.liquidx.WebViewScreenSaver

agologan commented 6 months ago

Added paths to the docs. Thank you @xmddmx .