From 9bcbfc02db4f5e2e5a9d4d4de1b4224700ccaeaa Mon Sep 17 00:00:00 2001 From: Gorgone Date: Mon, 19 Oct 2020 12:56:54 +0200 Subject: [PATCH] Update _cmd_build rework custom folder rules 1. _default_confdir 2. _custom_confdir cmd overrules toolchaincfg --- support/functions/_cmd_build | 25 +++++++++++++++---------- 1 file changed, 15 insertions(+), 10 deletions(-) diff --git a/support/functions/_cmd_build b/support/functions/_cmd_build index d75db82..780ad1f 100644 --- a/support/functions/_cmd_build +++ b/support/functions/_cmd_build @@ -126,20 +126,25 @@ _cmd_build(){ done #change default oscam CONF_DIR -if [ "$CUSTOM_CONFDIR" == "not_set" ] && [ ${#_oscamconfdir_custom} -lt 4 ]; -then - CONFDIR="$_oscamconfdir_default" - cdtag="CONF_DIR=$CONFDIR" -elif [ ${#_oscamconfdir_custom} -gt 4 ]; + +CONFDIR="$_oscamconfdir_default" +cdtag="CONF_DIR=$CONFDIR" + +if [ ! -z "$_oscamconfdir_custom" ]; then - CONFDIR="$_oscamconfdir_custom" - cdtag="${r_l}custom CONF_DIR=$CONFDIR (via toolchain.cfg)" + if [ ! "$_oscamconfdir_custom" == "not_set" ]; + then + CONFDIR="$_oscamconfdir_custom" + cdtag="${r_l}custom CONF_DIR=$_oscamconfdir_custom (via toolchain.cfg)" + fi fi -if [ ${#CUSTOM_CONFDIR} -gt 4 ]; + +if [ ! "$CUSTOM_CONFDIR" == "not_set" ]; then - CONFDIR="$CUSTOM_CONFDIR" - cdtag="${r_l}custom CONF_DIR=$CONFDIR (via commandline)" + CONFDIR="$_oscamconfdir_custom" + cdtag="${r_l}custom CONF_DIR=$CUSTOM_CONFDIR (via CUSTOM_CONFDIR)" fi + printf "$y_l\n | set : ${cdtag}$w_l" #patching