Longer variable names
This commit is contained in:
parent
67b515d24b
commit
ab5fc8ca9d
|
@ -53,14 +53,14 @@ fi
|
||||||
function app_load_variables {
|
function app_load_variables {
|
||||||
app_name=$1
|
app_name=$1
|
||||||
|
|
||||||
var_name=${app_name}_variables
|
config_var_name=${app_name}_variables
|
||||||
if [ ! ${!var_name} ]; then
|
if [ ! ${!config_var_name} ]; then
|
||||||
echo $"${app_name}_variables was not found"
|
echo $"${app_name}_variables was not found"
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
|
|
||||||
eval "varname=(\${$var_name[@]})"
|
eval "configvarname=(\${$config_var_name[@]})"
|
||||||
for v in "${varname[@]}"
|
for v in "${configvarname[@]}"
|
||||||
do
|
do
|
||||||
read_config_param $v
|
read_config_param $v
|
||||||
done
|
done
|
||||||
|
@ -70,13 +70,13 @@ function app_load_variables {
|
||||||
function app_save_variables {
|
function app_save_variables {
|
||||||
app_name=$1
|
app_name=$1
|
||||||
|
|
||||||
var_name=${app_name}_variables
|
config_var_name=${app_name}_variables
|
||||||
if [ ! ${!var_name} ]; then
|
if [ ! ${!config_var_name} ]; then
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
|
|
||||||
eval "varname=(\${$var_name[@]})"
|
eval "configvarname=(\${$config_var_name[@]})"
|
||||||
for v in "${varname[@]}"
|
for v in "${configvarname[@]}"
|
||||||
do
|
do
|
||||||
write_config_param $v "${!v}"
|
write_config_param $v "${!v}"
|
||||||
done
|
done
|
||||||
|
|
Loading…
Reference in New Issue