From f4ca036eec840d135c74be97e9cc594569d6c32d Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Fri, 31 Dec 2021 10:37:38 -0300 Subject: Fix: hydra_yaml_param regexp --- lib/hydra/deploy | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/hydra/deploy b/lib/hydra/deploy index ed281d1..84a9fda 100644 --- a/lib/hydra/deploy +++ b/lib/hydra/deploy @@ -130,9 +130,10 @@ function hydra_yaml_param { local param="$1" local file="$2" - #grep "^$param: " $file | cut -d ' ' -f 2 | sed -e "s/'//g" -e 's/"//g' - #grep "^$param" $file | sed -e "s/^$param//" | cut -d ':' -f 2 | sed -e "s/'//g" -e 's/"//g' -e "s/ //g" - grep "^$param:[^:]" $file | sed -e "s/^$param://" | sed -e "s/'//g" -e 's/"//g' -e "s/ //g" + #grep "^$param: " $file | cut -d ' ' -f 2 | sed -e "s/'//g" -e 's/"//g' + #grep "^$param" $file | sed -e "s/^$param//" | cut -d ':' -f 2 | sed -e "s/'//g" -e 's/"//g' -e "s/ //g" + #grep "^$param:[^:]" $file | sed -e "s/^$param://" | sed -e "s/'//g" -e 's/"//g' -e "s/ //g" + grep "^$param *:[^:]" $file | sed -e "s/^$param *://" | sed -e "s/'//g" -e 's/"//g' -e "s/ //g" } # Create puppet folder structure -- cgit v1.2.3