mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
[yolo] Add head -n1, because on some setups like stupid OVH, 'VERSION_ID' is duplicated :|
This commit is contained in:
parent
d420bb240f
commit
9e87da8d26
1 changed files with 1 additions and 1 deletions
|
@ -94,7 +94,7 @@ class MyMigration(Migration):
|
|||
# with /etc/lsb-release for instance -_-)
|
||||
# Instead, we rely on /etc/os-release which should be the raw info from
|
||||
# the distribution...
|
||||
return int(check_output("grep VERSION_ID /etc/os-release | tr '\"' ' ' | cut -d ' ' -f2"))
|
||||
return int(check_output("grep VERSION_ID /etc/os-release | head -n 1 | tr '\"' ' ' | cut -d ' ' -f2"))
|
||||
|
||||
def yunohost_major_version(self):
|
||||
return int(get_installed_version("yunohost").split('.')[0])
|
||||
|
|
Loading…
Add table
Reference in a new issue