From 238905099eb7d6a0ee44dadc2ff051692d8831f6 Mon Sep 17 00:00:00 2001 From: jao Date: Tue, 15 Oct 2019 21:36:23 +0100 Subject: A second attempt at fixing #405 This time taking into account that ~/.config/xmobar could be populated --- src/Xmobar/App/Config.hs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/Xmobar/App/Config.hs') diff --git a/src/Xmobar/App/Config.hs b/src/Xmobar/App/Config.hs index 8c2bef8..48209d3 100644 --- a/src/Xmobar/App/Config.hs +++ b/src/Xmobar/App/Config.hs @@ -96,8 +96,8 @@ xmobarConfigDir = -- Several directories are considered. In order of preference: -- -- 1. The directory specified in the @XMOBAR_DATA_DIR@ environment variable. --- 2. The @~\/.xmobar@ directory. --- 3. The @XDG_DATA_HOME/xmobar@ directory. +-- 2. The @XDG_DATA_HOME/xmobar@ directory. +-- 3. The @~\/.xmobar@ directory. -- -- The first directory that exists will be used. If none of the -- directories exist then (1) will be used if it is set, otherwise (2) @@ -106,8 +106,8 @@ xmobarConfigDir = xmobarDataDir :: IO String xmobarDataDir = findFirstDirWithEnv True "XMOBAR_DATA_DIR" - [ getAppUserDataDirectory "xmobar" - , getXdgDirectory XdgData "xmobar" + [ getXdgDirectory XdgData "xmobar" + , getAppUserDataDirectory "xmobar" ] -- | Helper function that will find the first existing directory and -- cgit v1.2.3