dragotin / kraft

Kraft helps to handle your daily quotes and invoices in your small business.
http://volle-kraft-voraus.de
GNU General Public License v2.0
60 stars 19 forks source link

Feature Request: Introduce environment variables KRAFTRC and KRAFTDBRC for the fixed-location config files #174

Closed noseshimself closed 2 years ago

noseshimself commented 2 years ago

if the variables are set, Kraft should look at the specified locations for the files instead of the fixed location .config. This avoids adding links to the real locations.

dragotin commented 2 years ago

That is already possible. Use XDG_CONFIG_HOME to set the base directory for the config. Other XDG_ variables might also be interesting.

Note: Kraft might start the Akonadi subsystem by respective functions from the Akonadi libraries. That happens to use the the XDG_ variables as well. So both Kraft and Akonadi (aka KAddressbook) should be run based on the same XDG_CONFIG_HOME

See https://specifications.freedesktop.org/basedir-spec/latest/ar01s03.html for details.

noseshimself commented 2 years ago

Setting XDG_ variables will of course hit all applications in all desktop environments. In bash it is of course possible to start a program with an individual environment (by specifying the variables in front of the executable's path) but all subprocesses will inherit it, too, and I don't have the slightest idea what it will do to Grantlee or Weasyprint so I did not want to try that.