You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As discussed in #17, we would like to have a way for configuring some application-wide settings through a configuration file.
Solution
We will use a 2-level configuration. Any given setting will be first read from a configuration file, if the configuration file does not exist or does not specify the desired setting, a sensible default should be used.
The configuration file will be in JSON format.
The file location is pre-defined, and varies based on operating system:
Linux: we'll follow the XDG spec and the file will be placed at $XDG_CONFIG_HOME/icm/settings.json. $HOME/.config will be used in place of XDG_CONFIG_HOME if it is not set.
MacOS: I could not find any official up-to-date documents, but archived documents suggest we should place our file at $HOME/Library/Application Support/icm/settings.json. I found other people corroborating the information and no suggestion of alternative locations.
Windows: I could not find any official documents, but the overall consensus on the internet is that application configuration files should be placed within "%AppData%", so we'll use %AppData%\icm\settings.json
The implementation can use the two variables we already wish to parameterize (HTTP server host and port) to provide a more complete feature and better validate itself.
This issue does not cover features for manipulating the settings file.
The text was updated successfully, but these errors were encountered:
About
As discussed in #17, we would like to have a way for configuring some application-wide settings through a configuration file.
Solution
We will use a 2-level configuration. Any given setting will be first read from a configuration file, if the configuration file does not exist or does not specify the desired setting, a sensible default should be used.
The configuration file will be in JSON format.
The file location is pre-defined, and varies based on operating system:
$XDG_CONFIG_HOME/icm/settings.json
.$HOME/.config
will be used in place ofXDG_CONFIG_HOME
if it is not set.$HOME/Library/Application Support/icm/settings.json
. I found other people corroborating the information and no suggestion of alternative locations.%AppData%\icm\settings.json
The implementation can use the two variables we already wish to parameterize (HTTP server host and port) to provide a more complete feature and better validate itself.
This issue does not cover features for manipulating the settings file.
The text was updated successfully, but these errors were encountered: