From 6f37db72d4a1035928ddedc3ef60001debe6a30c Mon Sep 17 00:00:00 2001 From: Claudius Heine Date: Mon, 3 Jul 2017 13:46:34 +0200 Subject: [PATCH] Compare the distro_id in lowercase For me 'distro.id()' returned 'ubuntu' and thats not equal to 'Ubuntu'. This patch converts the distro id to lowercase before comparing it. Signed-off-by: Claudius Heine --- kas/config.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kas/config.py b/kas/config.py index 30a3e31..6bc23e7 100644 --- a/kas/config.py +++ b/kas/config.py @@ -79,11 +79,11 @@ class Config: started by kas. """ distro_id = get_distro_id() - if distro_id in ['fedora', 'SuSE', 'opensuse']: + if distro_id.lower() in ['fedora', 'suse', 'opensuse']: self.environ = {'LC_ALL': 'en_US.utf8', 'LANG': 'en_US.utf8', 'LANGUAGE': 'en_US'} - elif distro_id in ['Ubuntu', 'debian']: + elif distro_id.lower() in ['debian', 'ubuntu']: self.environ = {'LC_ALL': 'en_US.UTF-8', 'LANG': 'en_US.UTF-8', 'LANGUAGE': 'en_US:en'}