From c863d2c3c9773ba7312420d00262d927ae1aab8b Mon Sep 17 00:00:00 2001 From: "Matthias C. M. Troffaes" Date: Wed, 16 May 2018 09:11:50 +0100 Subject: [PATCH] Fix config folder. --- src/main.d | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main.d b/src/main.d index 13c07211..6b2ff587 100644 --- a/src/main.d +++ b/src/main.d @@ -8,15 +8,15 @@ int main(string[] args) { // Determine the user home directory. // Need to avoid using ~ here as expandTilde() below does not interpret correctly when running under init.d scripts - string homePath = environment.get("XDG_CONFIG_HOME"); - if (homePath == ""){ + string configPath = environment.get("XDG_CONFIG_HOME"); + if (configPath == ""){ // XDG_CONFIG_HOME does not exist on systems where X11 is not present - ie - headless systems / servers // Get HOME environment variable - homePath = environment.get("HOME"); + configPath = environment.get("HOME") ~ "/.config"; } // configuration directory - string configDirName = homePath ~ "/.config/onedrive"; + string configDirName = configPath ~ "/onedrive"; // only download remote changes bool downloadOnly; // override the sync directory