From f37221c8333d91be0d350880d0c50537b9b18b18 Mon Sep 17 00:00:00 2001 From: r00t Date: Tue, 11 Apr 2017 08:19:24 -0400 Subject: [PATCH] some further tweaking of conf paths --- bdisk/host.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/bdisk/host.py b/bdisk/host.py index f282c16..aa0b216 100755 --- a/bdisk/host.py +++ b/bdisk/host.py @@ -28,7 +28,9 @@ def getConfig(conf_file='/etc/bdisk/build.ini'): conf = False # define some defailt conf paths in case we're installed by # a package manager. in order of the paths we should search. - currentdir = os.path.abspath('{0}/../extra/dist.build.ini'.format(os.path.dirname(os.path.realpath(__file__)))) + currentdir = os.path.dirname(os.path.realpath(__file__)) + currentdir_user = os.path.abspath('{0}/../dist.build.ini'.format(currentdir)) + currentdir_def = os.path.abspath('{0}/../extra/dist.build.ini'.format(currentdir)) default_conf_paths = ['/etc/bdisk/build.ini', '/usr/share/bdisk/build.ini', '/usr/share/bdisk/extra/build.ini', @@ -38,7 +40,8 @@ def getConfig(conf_file='/etc/bdisk/build.ini'): '/opt/dev/bdisk/build.ini', '/opt/dev/bdisk/extra/build.ini', '/opt/dev/bdisk/extra/dist.build.ini', - currentdir] + currentdir_user, + currentdir_def] # if we weren't given one/using the default... if conf_file == '/etc/bdisk/build.ini': if not os.path.isfile(conf_file):