Browse code

Merge "Create config file in merge_config_file"

Jenkins authored on 2015/04/18 04:32:24
Showing 2 changed files
... ...
@@ -86,6 +86,14 @@ function merge_config_file {
86 86
     local matchgroup=$2
87 87
     local configfile=$3
88 88
 
89
+    # note, configfile might be a variable (note the iniset, etc
90
+    # created in the mega-awk below is "eval"ed too, so we just leave
91
+    # it alone.
92
+    local real_configfile=$(eval echo $configfile)
93
+    if [ ! -f $real_configfile ]; then
94
+        touch $real_configfile
95
+    fi
96
+
89 97
     get_meta_section $file $matchgroup $configfile | \
90 98
     $CONFIG_AWK_CMD -v configfile=$configfile '
91 99
         BEGIN {
... ...
@@ -8,6 +8,8 @@ TOP=$(cd $(dirname "$0")/.. && pwd)
8 8
 source $TOP/inc/ini-config
9 9
 source $TOP/inc/meta-config
10 10
 
11
+set -e
12
+
11 13
 # check_result() tests and reports the result values
12 14
 # check_result "actual" "expected"
13 15
 function check_result {