Merge branch 'dev' into bookworm

This commit is contained in:
tituspijean 2024-04-20 10:45:38 +02:00
commit 3182aa85e7
No known key found for this signature in database
GPG key ID: EF3B0D7CC0A94720
3 changed files with 15 additions and 6 deletions

6
debian/changelog vendored
View file

@ -4,6 +4,12 @@ yunohost (12.0.0) unstable; urgency=low
-- Alexandre Aubin <alex.aubin@mailoo.org> Thu, 04 May 2023 20:30:19 +0200
yunohost (11.2.11.2) stable; urgency=low
- More oopsies (22b30c79)
-- Alexandre Aubin <alex.aubin@mailoo.org> Thu, 11 Apr 2024 16:03:20 +0200
yunohost (11.2.11.1) stable; urgency=low
- Missing import oopsi (29c597ed)

View file

@ -843,7 +843,7 @@ ynh_get_debian_release() {
_acceptable_path_to_delete() {
local file=$1
local forbidden_paths=$(ls -d / /* /{var,home,usr}/* /etc/{default,sudoers.d,yunohost,cron*} /etc/yunohost/{apps,domains,hooks.d} /opt/yunohost)
local forbidden_paths=$(ls -d / /* /{var,home,usr}/* /etc/{default,sudoers.d,yunohost,cron*} /etc/yunohost/{apps,domains,hooks.d} /opt/yunohost 2> /dev/null)
# Legacy : A couple apps still have data in /home/$app ...
if [[ -n "${app:-}" ]]

View file

@ -148,16 +148,19 @@ class AppResource:
self.manager = manager
properties = self.default_properties | properties
# It's not guaranteed that this info will be defined, e.g. during unit tests, only small resource snippets are used, not proper manifests
app_upstream_version = ""
if manager and manager.wanted and "version" in manager.wanted:
app_upstream_version = manager.wanted["version"].split("~")[0]
elif manager and manager.current and "version" in manager.current:
app_upstream_version = manager.current["version"].split("~")[0]
replacements: dict[str, str] = {
"__APP__": self.app,
"__YNH_ARCH__": system_arch(),
"__YNH_DEBIAN_VERSION__": debian_version(),
"__YNH_DEBIAN_VERSION_ID__": debian_version_id(),
"__YNH_APP_UPSTREAM_VERSION__": (
manager.wanted["version"].split("~")[0]
if manager.wanted
else manager.current["version"].split("~")[0]
),
"__YNH_APP_UPSTREAM_VERSION__": app_upstream_version,
}
def recursive_apply(function: Callable, data: Any) -> Any: