Rafiuth/Soggfy

Path settings for portable or sandbox operation

just2cents opened this issue · 3 comments

in release 2.5.0, config.json (and log.txt) were in the same directory as injector.exe. This way, I could run a semi-portable installation by copying just the Spotify prefs and user credentials to %appdata% and run Spotify from any directory, e.g. a shared directory in a Windows sandbox.

Release 2.7.1 seems to read/write config.json only from %localappdata%\Soggfy so I have to deal also with this configuration file.

Is there an way to have at least the Soggfy config.json in a user definable directory?

Nope, this behavior is hardcoded as of now.

I take you're using the injector rather than copying the dlls to the spotify folder? If so I think having it search for config.json in the soggfy folder before localappdata could work, but I'm open to better ideas.

For me I like the simple idea of checking the current directory for a config. For the injector and dll method, if the config doesen't exist in the current directory it should use appdata.

I've implemented a heuristic in the latest release that will pick the directory containing SpotifyOggDumper.dll if config.json already exists there or if %localappdata%/Soggfy doesn't exist and the DLL was loaded by the injector.