Allowing mbsync to respect the XDG base directory specification
mailbox synchronizer
Brought to you by:
ossi
|
From: Wyatt S. <cw...@wy...> - 2020-05-07 23:02:23
|
Hello, all!
I have found mbsync to work well for me, but encountered minor frustration in regards to the default
config file location. I like to keep my $HOME very clean (in stark contrast to my home), and
therefore tend to keep all my configuration files in ~/.config. This was not a huge issue
since the --config option exists, but I have wound up with 3 scripts on my system that call mbsync,
and all of them need to be passed the --command option. If for some reason I ever move the config
file, I will need to remember to update all 3 scripts, or else I will be left with a broken system
(due to my own stupidity).
Considering this, I would like to submit the following patch which has mbsync look for a config
file in 3 places in the following order:
1. $MBSYNC_CONFIG - a user-set environment variable
2. $XDG_CONFIG_HOME/mbsync
3. ~/.mbsync (the legacy location)
This patch still respects the --config option superseding these locations.
Please let me know your thoughts, and have a lovely day.
--Wyatt Sheffield
|