rfvgyhn / min-ed-launcher

Minimal Elite Dangerous Launcher
MIT License
251 stars 9 forks source link

Default setting location seems to be ignored when $XDG_CONFIG_DIR (or similar relevant env var) is unset #77

Closed nojusr closed 1 year ago

nojusr commented 1 year ago

Describe the bug/error I was trying to setup my local install of ED to use this launcher instead of the default ED launcher, and I was unable to use the /edh4 argument to set my version (i'd get a list of available products, which, I assume is the default output when the product argument is not recognized). I initially suspected a misplaced config file: Documentation states that if $XDG_CONFIG_DIR is unset, then the configuration shall be placed in ~/.config/min-ed-launcher/settings.json. I've checked, the file is there and it's filterOverrides is properly set to it's default values.

The Debug logs paint an interesting picture: Debug log

2022-12-09 23:05:41.690 +02:00 [INF] Elite Dangerous: Minimal Launcher - v0.7.5+e47c3cd3
2022-12-09 23:05:41.777 +02:00 [DBG]
    Args: [|"/home/nojus/.local/share/Steam/ubuntu12_32/reaper"; "SteamLaunch";
  "AppId=359320"; "--";
  "/home/nojus/.local/share/Steam/ubuntu12_32/steam-launch-wrapper"; "--";
  "/home/nojus/.local/share/Steam/steamapps/common/SteamLinuxRuntime_soldier/_v2-entry-point";
  "--verb=waitforexitandrun"; "--";
  "/home/nojus/.local/share/Steam/steamapps/common/Proton 6.3/proton";
  "waitforexitandrun";
  "/mnt/main/games/steam-games/steamapps/common/Elite Dangerous/EDLaunch.exe";
  "/Steam"; "/novr"; "/autorun"; "/autoquit"; "/edh4"|]
    OS: Linux64
    Env: STEAM_COMPAT_DATA_PATH=/mnt/main/games/steam-games/steamapps/compatdata/359320

2022-12-09 23:05:41.780 +02:00 [DBG] Reading settings from '/home/nojus/.config/min-ed-launcher/settings.json'
2022-12-09 23:05:41.915 +02:00 [DBG] Settings: { }
[ further logs irrelevant...] 

Seems like the launcher is aware from the proper position of the setting file, but for some reason is unable to parse it's contents.

pan-mroku commented 1 year ago

Maybe it's a problem with parsing? Could you paste your config? Without any private data, of course.

rfvgyhn commented 1 year ago

Yeah, it looks like a parsing issue. I'm not sure why it's showing an empty settings object instead of an error though. Like @pan-mroku mentioned, can you provide the contents of you settings file?