From 7c28ec1c1b51dee9c39c6beab8f5df16b62ee632 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sun, 29 Oct 2017 23:37:51 +0100 Subject: [PATCH] [enh] Adding an app helper to display infos --- data/helpers.d/print | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/data/helpers.d/print b/data/helpers.d/print index 36f4a120e..740933acb 100644 --- a/data/helpers.d/print +++ b/data/helpers.d/print @@ -5,6 +5,14 @@ ynh_die() { exit "${2:-1}" } +# Display a message in the 'INFO' logging category +# +# usage: ynh_info "Some message" +ynh_info() +{ + echo "$1" >>"$YNH_STDINFO" +} + # Ignore the yunohost-cli log to prevent errors with conditionals commands # usage: ynh_no_log COMMAND # Simply duplicate the log, execute the yunohost command and replace the log without the result of this command