display-switch icon indicating copy to clipboard operation
display-switch copied to clipboard

Support multiple configuration file locations

Open haimgel opened this issue 3 years ago • 2 comments

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.

haimgel avatar Sep 20 '20 15:09 haimgel

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.

pm215 avatar Feb 22 '21 17:02 pm215

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.

chocmake avatar Oct 28 '22 10:10 chocmake