summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrea Scarpino <andrea@archlinux.org>2013-04-15 23:19:39 +0200
committerAndrea Scarpino <andrea@archlinux.org>2013-05-14 14:24:55 +0200
commit50373acdaf8ecd56d9fc0b31ee2f8f06f448c1a3 (patch)
tree76cd55632feaab8ac7a973511c429a91052abd7a
parent848789c2d777e353e7c07320b68a7480beb107a6 (diff)
Give home configurations precedence over system ones
Change-Id: Ib0c4cf47c0ff5f716949cc5653ba27dad3558489 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
-rw-r--r--src/qtchooser/main.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/qtchooser/main.cpp b/src/qtchooser/main.cpp
index da54b16..514503d 100644
--- a/src/qtchooser/main.cpp
+++ b/src/qtchooser/main.cpp
@@ -272,12 +272,13 @@ vector<string> ToolWrapper::searchPaths() const
{
vector<string> paths;
- // search the XDG config location directories
- paths = stringSplit(qgetenv("XDG_CONFIG_DIRS", "/etc/xdg").c_str());
-
string localDir = qgetenv("XDG_CONFIG_HOME", userHome() + PATH_SEP ".config");
paths.push_back(localDir);
+ // search the XDG config location directories
+ vector<string> xdgPaths = stringSplit(qgetenv("XDG_CONFIG_DIRS", "/etc/xdg").c_str());
+ paths.insert(paths.end(), xdgPaths.begin(), xdgPaths.end());
+
for (vector<string>::iterator it = paths.begin(); it != paths.end(); ++it)
*it += "/qtchooser/";