From 353049c093cd5bed4f2b257f777ef012c8968078 Mon Sep 17 00:00:00 2001 From: Maniack Crudelis Date: Sat, 2 May 2020 01:07:19 +0200 Subject: [PATCH] Really ignore ynh_clean_setup... --- sub_scripts/testing_process.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sub_scripts/testing_process.sh b/sub_scripts/testing_process.sh index 989d7c4..f154a2a 100644 --- a/sub_scripts/testing_process.sh +++ b/sub_scripts/testing_process.sh @@ -101,14 +101,17 @@ CHECK_TEMPLATE () { helper_like="$(echo "$template_output" | sed -n '/:[[:blank:]]*ynh_/p')" # Remove ynh_ like helpers template_output="$(echo "$template_output" | sed '/:[[:blank:]]*ynh_/d')" + + # Ignore known functions # Remove find_mails, which is a part of ynh_send_readme_to_admin template_output="$(echo "$template_output" | sed '/find_mails/d')" # And at_least_one, part of ynh_get_scalable_phpfpm template_output="$(echo "$template_output" | sed '/at_least_one/d')" - # Remove ynh_clean_setup, an official helper defined only in comment into official helpers - template_output="$(echo "$template_output" | sed '/at_least_one/d')" show_error "Do not use specific functions aside of ynh helpers." "Keep your code linear directly into the scripts to ease the reading of your scripts" + # Ignore known helpers + # Remove ynh_clean_setup, an official helper defined only in comment into official helpers + helper_like="$(echo "$helper_like" | sed '/ynh_clean_setup/d')" ### Detect functions that looks like YunoHost helpers if [ -n "$helper_like" ]