From dc2194dfcfafe3009ccffa0888d961958763dd5a Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sat, 9 Mar 2019 20:26:30 +0100 Subject: [PATCH] Add a warning if required YunoHost version is still 2.x --- package_linter.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/package_linter.py b/package_linter.py index bb6e732..0e1d309 100755 --- a/package_linter.py +++ b/package_linter.py @@ -359,6 +359,18 @@ class App(): "but rather the website or repo of the upstream app itself..." ) + yunohost_version_req = manifest.get("requirements", {}).get("yunohost", None) + if yunohost_version_req: + major_version = yunohost_version_req.split()[-1] + if major_version.startswith("2"): + print_warning( + "YunoHost version requirement is still 2.x ... Good job if " + "it does still work on Jessie !... But are you really sure " + "about that ;) ? be careful that many new helpers you might " + "already be playing with are only available on 3.x..." + ) + + class Script():