mirror of
https://github.com/openSUSE/osc.git
synced 2025-09-07 21:58:41 +02:00
Use distro module to detect distro on all python versions
Also, add a related Recommends to to the spec file
This commit is contained in:
@@ -4203,10 +4203,7 @@ def read_meta_from_spec(specfile, *args):
|
||||
def _get_linux_distro():
|
||||
if distro is not None:
|
||||
return distro.id()
|
||||
elif sys.version_info >= (3, 8):
|
||||
return None
|
||||
# compatibility for Python 2.6 to 3.7
|
||||
return platform.linux_distribution()[0]
|
||||
return None
|
||||
|
||||
|
||||
def get_default_editor():
|
||||
|
Reference in New Issue
Block a user