Open jayare5 opened 2 years ago
It saves the current in-memory settings to the retroarch.cfg on exit (or when you 'save current config'). If you 'load a config file' and then exit, does that essentially do the same thing?
It saves the current in-memory settings to the retroarch.cfg on exit (or when you 'save current config'). If you 'load a config file' and then exit, does that essentially do the same thing?
Good idea :P but no, I just tested it. Doesn't work that way. It only saves on exit if the current loaded config is the standard retroarch.cfg in the standard directory.
If I load another config, and save on exit is enabled, that doesn't rewrite the standard retroarch.cfg.
EDIT: Mind you, when I said Good idea I meant it's a good thing to check that first, but I don't think it would be a good idea if that's how it worked because that could mean accidentally erasing the standard retroarch.cfg by just loading a new one.
It is best that loading is a temporary load, while a new option makes it clear that it's a "permanent" load that will persist after a restart.
It saves the current in-memory settings to the retroarch.cfg on exit (or when you 'save current config'). If you 'load a config file' and then exit, does that essentially do the same thing?
From:
The settings should be saved to retroarch.cfg.
The settings have not been saved to retroarch.cfg.
Main Menu -> Configuration File -> Load Configuration
, select your retroarch.cfg fileMain Menu -> Quit
-- It does not save the settings to retroarch.cfg.You can find this information under Information/System Information
Hi!
I have this working for Lakka (not yet as build patch, but tested): https://github.com/ToKe79/RetroArch/commit/d623d54f856b05ebc4a713790cf9d847d0e0a26c.
it does what @jayare5 actually requests.
it adds new item in Main Menu -> Configuration -> Save To Default Configuration File (sublabel: Overwrite default configuration file.). When selected, current configuration is always saved to (in Lakka) /storage/.config/retroarch/retroarch.cfg
.
So you can load a custom config file and then select this new item and the settings will be written to the default config file.
the part where the config is saved / save path is determined, needs to be modified for other platforms (Windows, Mac, ...). currently this works only on Linux I guess. Therefore all my changes depend on HAVE_LAKKA
define, so it does not break other platforms, if I would decide to upstream it as is.
For the code to determine the save path I reused this part:
above this part there are code paths for different platforms, but some of them rely on creating empty configuration file (e.g. conf = ...; if (!conf) ...
), so i did not reuse all code.
@sonninnos, @hizzlekizzle - maybe you can expand / optimize my code? I'm no coder by job, only a hobbist, so your help is appreciated :-)
Hi!
I have this working for Lakka (not yet as build patch, but tested): ToKe79@d623d54.
it does what @jayare5 actually requests.
it adds new item in Main Menu -> Configuration -> Save To Default Configuration File (sublabel: Overwrite default configuration file.). When selected, current configuration is always saved to (in Lakka)
/storage/.config/retroarch/retroarch.cfg
.So you can load a custom config file and then select this new item and the settings will be written to the default config file.
the part where the config is saved / save path is determined, needs to be modified for other platforms (Windows, Mac, ...). currently this works only on Linux I guess. Therefore all my changes depend on
HAVE_LAKKA
define, so it does not break other platforms, if I would decide to upstream it as is.For the code to determine the save path I reused this part:
above this part there are code paths for different platforms, but some of them rely on creating empty configuration file (e.g.
conf = ...; if (!conf) ...
), so i did not reuse all code.@sonninnos, @hizzlekizzle - maybe you can expand / optimize my code? I'm no coder by job, only a hobbist, so your help is appreciated :-)
Good work! I suggest that your code is applied automatically once a config file has been loaded, so the default config file is overwritten when you hit Main Menu -> Quit
-- the required way to close RetroArch in Android to save the configuration on quit.
Good work! I suggest that your code is applied automatically once a config file has been loaded, so the default config file is overwritten when you hit
Main Menu -> Quit
-- the required way to close RetroArch in Android to save the configuration on quit.
Unfortunately not, still on quit saves to the loaded config file - I did not change this behavior (not sure if this is globally wanted). With this patch (currently tested only on Lakka) before Quit you can use
Main Menu → Configuration → Save To Default Configuration File
to overwrite the default retroarch.cfg
(in Lakka in ~/.config/retroarch/retrorach.cfg
). However there are different code paths for different platforms to determine the save location of the default config file, so this change currently does not work on Android, Mac/OSX, iOS, Windows, ...
To support other platforms, this part needs to be expaded:
in same way as for example here: https://github.com/libretro/RetroArch/blob/fdd010aebc42ba9080204ce5f6b363dd886a6c1c/configuration.c#L3252-L3360
Good work! I suggest that your code is applied automatically once a config file has been loaded, so the default config file is overwritten when you hit
Main Menu -> Quit
-- the required way to close RetroArch in Android to save the configuration on quit.Unfortunately not, still on quit saves to the loaded config file - I did not change this behavior (not sure if this is globally wanted). With this patch (currently tested only on Lakka) before Quit you can use
Main Menu → Configuration → Save To Default Configuration File
to overwrite the default
retroarch.cfg
(in Lakka in~/.config/retroarch/retrorach.cfg
). However there are different code paths for different platforms to determine the save location of the default config file, so this change currently does not work on Android, Mac/OSX, iOS, Windows, ...To support other platforms, this part needs to be expaded:
in same way as for example here:
On many Android devices, you can't access certain folders (such as /storage/emulated/0/Android/data/) without special permissions. This makes it tricky to copy a RetroArch configuration file (retroarch.cfg) to its usual location (/storage/emulated/0/Android/data/com.retroarch/files/retroarch.cfg). The result? Settings have to be done manually, taking up precious gaming time.
Your solution will streamline this process and save you the hassle!
Currently there is no way to load a config file for the whole RetroArch and allowing it to persist after closing / restart / relaunch. This could be fixed if we had something similar to core overrides saving / shader saving options, I'd like to see 2 options for the main retroarch.cfg (in Main Menu / Configuration File):
Expected behavior:
Actual behavior: If you were to make a new .cfg file and loaded it, it will always go away after restarting.
I would use this to deal with 3 issues:
Currently, if you load a cfg file that has a different playlist folder, it will just break the currently loaded playlists and not show the new ones because they require a restart to update, but restarting means it will load the default cfg and thus the playlists wouldn't change. Instead of fixing that issue alone, it seems easier to just add this option to rewrite the default cfg as a workaround.
When I use a different setup, like when I move to a different TV for a day or more, or even visit a friend for example, I may want to use a different config made for this other TV's resolution and stay with those settings even after turning off and on the device. I guess on a PC it's a lot easier, but this is more necessary when using Lakka devices like the Raspberry Pi, where you can't just easily go into the files, plus those are compatible with CRTs too, which require very different configs.
Multiple people can share the same install of RetroArch by permanently loading completely customized configurations which can change everything for each person's config preferences / list of games!