aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHarry Jeffery <harry@exec64.co.uk>2018-05-05 12:07:20 +0100
committerHarry Jeffery <harry@exec64.co.uk>2018-05-05 12:07:20 +0100
commit9b1968821d73489259ab6c274949efb1f4dfe54d (patch)
tree367315d497e8acba0128ab9494d7f90f059513b3
parenta65b30b5dab60392ee86638652526d02da8788c0 (diff)
downloadimv-9b1968821d73489259ab6c274949efb1f4dfe54d.tar.gz
Update config search paths
As per XDG spec, if $XDG_CONFIG isn't set, we should fall back to $HOME/.config Fixes #124
-rw-r--r--src/imv.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/imv.c b/src/imv.c
index 27016aa..9393dad 100644
--- a/src/imv.c
+++ b/src/imv.c
@@ -908,9 +908,10 @@ static char *get_config_path(void)
{
const char *config_paths[] = {
"$imv_config",
+ "$XDG_CONFIG_HOME/imv/config",
+ "$HOME/.config/imv/config",
"$HOME/.imv_config",
"$HOME/.imv/config",
- "$XDG_CONFIG_HOME/imv/config",
"/usr/local/etc/imv_config",
"/etc/imv_config",
};