From 5262b52cffd7ed649a69fd62f74fa79a05d88597 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Tue, 18 Jun 2019 16:03:00 +0200 Subject: [PATCH] Add a helper to easily return stuff in config script --- data/helpers.d/logging | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/data/helpers.d/logging b/data/helpers.d/logging index 9e8cc06cb..ed8054622 100644 --- a/data/helpers.d/logging +++ b/data/helpers.d/logging @@ -282,6 +282,16 @@ ynh_script_progression () { ynh_print_info "[$progression_bar] > ${message}${print_exec_time}" } +# Return data to the Yunohost core for later processing +# (to be used by special hooks like app config panel and core diagnosis) +# +# usage: ynh_return somedata +# +# Requires YunoHost version 3.6.0 or higher. +ynh_return () { + echo "$1" >> "$YNH_STDRETURN" +} + # Debugger for app packagers # # usage: ynh_debug [--message=message] [--trace=1/0]