diff options
author | Guido Günther <agx@sigxcpu.org> | 2022-12-30 13:27:55 +0100 |
---|---|---|
committer | Guido Günther <agx@sigxcpu.org> | 2022-12-30 13:27:55 +0100 |
commit | 262383ed118432bc157c5f992c0aff9240b998c8 (patch) | |
tree | 5750cb80fafbccee542719fb2f0e65b88737df5a /whatmaps/distro.py | |
parent | 995da8caee1785555bcc26f52ed6f0a34470e48a (diff) | |
parent | e28c99d3fc7c391de039321e87b5ce12eae38572 (diff) |
Merge tag 'v0.0.13' into debian/master
v0.0.13
Diffstat (limited to 'whatmaps/distro.py')
-rw-r--r-- | whatmaps/distro.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/whatmaps/distro.py b/whatmaps/distro.py index 29d2dc2..d4f991b 100644 --- a/whatmaps/distro.py +++ b/whatmaps/distro.py @@ -112,6 +112,7 @@ class Distro(object): def detect(): return detect() + import whatmaps.debiandistro # noqa: E402 import whatmaps.redhatdistro # noqa: E402 @@ -129,10 +130,10 @@ def detect(): try: lsb_cmd = subprocess.Popen(['lsb_release', '--id', '-s'], stdout=subprocess.PIPE, - stderr=subprocess.PIPE) + stderr=subprocess.DEVNULL) output = lsb_cmd.communicate()[0] if not lsb_cmd.returncode: - id = output.strip() + id = output.decode().split('\n')[0].strip() except OSError: # id is None in this case pass |