feat(config): Try to load config.ini (#2324)

* Added .ini extension check to default config

* Added change to changelog and man page

* Added change to changelog and man page

* removed .vscode folder

* removed new lines in changelog
This commit is contained in:
Kamui
2020-12-23 08:52:30 -08:00
committed by GitHub
parent 218911c463
commit 89a723a4d9
3 changed files with 17 additions and 3 deletions

View File

@ -303,12 +303,23 @@ namespace file_util {
if (exists(confpath)) {
return confpath;
}
string iniConfPath = confpath.append(".ini");
if (exists(iniConfPath)) {
return iniConfPath;
}
}
if (env_util::has("HOME")) {
confpath = env_util::get("HOME") + "/.config/polybar/config";
if (exists(confpath)) {
return confpath;
}
string iniConfPath = confpath.append(".ini");
if (exists(iniConfPath)) {
return iniConfPath;
}
}
return "";
}