display-switch
display-switch copied to clipboard
Support multiple configuration file locations
The app should support multiple configuration file locations:
Linux
- Per-user config file
~/.config/display-switch/display-switch.ini
- Global config file
/etc/display-switch.ini
MacOS
- Per user config file
~/Library/Preferences/display-switch.ini
- Global config file
/Library/Preferences/display-switch.ini
Windows
- Per user config file
same-as-now
- Global config file
TBD
Should try to load per-user config file, and fall back to a global config file.
I think that supporting "use config file specified via a command line argument" would be useful as well; this would be handy for testing a new config file without having to copy it into the official installed-on-the-system location.
Would be nice if the CLI could detect the config file in the application directory on Windows (ie: wherever the CLI binary is located). In that sense it'd make it more portable. Perhaps could be considered for the global config file location, which would also match the behavior of various CLI programs (eg: yt-dlp, Nirsoft tools).
I also like the suggestion of being able to override the default path via an argument, particularly if one could bypass a per-user directory from being created initially.