Merge pull request #157 from YunoHost/actions/black

Format Python code with Black
This commit is contained in:
Alexandre Aubin 2024-07-23 19:46:32 +02:00 committed by GitHub
commit c35e07b47f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -2101,12 +2101,16 @@ class Manifest(TestSuite):
@test() @test()
def custom_install_dir(self): def custom_install_dir(self):
custom_install_dir = self.manifest.get("resources", {}).get("install_dir", {}).get("dir") custom_install_dir = (
self.manifest.get("resources", {}).get("install_dir", {}).get("dir")
)
if not custom_install_dir: if not custom_install_dir:
return return
if custom_install_dir.startswith("/opt/yunohost"): if custom_install_dir.startswith("/opt/yunohost"):
yield Warning("Installing apps in /opt/yunohost is deprecated ... YunoHost is about standardization, and the standard is to install in /var/www/__APP__ (yes, even if not a webapp, because whatever). Please stick to the default value. the resource system should automatically move the install dir if needed so you don't really need to think about backward compatibility.") yield Warning(
"Installing apps in /opt/yunohost is deprecated ... YunoHost is about standardization, and the standard is to install in /var/www/__APP__ (yes, even if not a webapp, because whatever). Please stick to the default value. the resource system should automatically move the install dir if needed so you don't really need to think about backward compatibility."
)
@test() @test()
def install_args(self): def install_args(self):