summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaxim Kuvyrkov <maxim.kuvyrkov@linaro.org>2019-02-26 10:49:37 +0000
committerMaxim Kuvyrkov <maxim.kuvyrkov@linaro.org>2019-02-26 10:49:37 +0000
commitd4758327b776c8072ec80b5f592187b7151ef96f (patch)
treef5010f3e4bf508d0d633cc64a3a9d9e388269125
parent917ec6b83427a40b511027418283afcce0be048f (diff)
tcwg_bmk-build.sh: Use "@build_num@" marker instead of "<build_num>"
"<build_num>" gets escaped into "\<build_num\>", which is not matched by "sed" in tcwg-benchmark.sh. Use "@" to avoid escape characters. Change-Id: I7e76975cc8561dbd1eeb1caa48dabaada09d6312
-rwxr-xr-xtcwg-benchmark.sh6
-rwxr-xr-xtcwg_bmk-build.sh4
2 files changed, 6 insertions, 4 deletions
diff --git a/tcwg-benchmark.sh b/tcwg-benchmark.sh
index fbb49111..34a8457f 100755
--- a/tcwg-benchmark.sh
+++ b/tcwg-benchmark.sh
@@ -216,8 +216,10 @@ boardname=$(echo "${NODE_NAME}" | sed 's/-bmk//').tcwglab
hw_type=$(print_hw_id_for_node "$NODE_NAME")
results_id=$(echo "$results_id" \
- | sed -e "s/<hw_type>/$hw_type/g" \
- -e "s/<build_num>/$BUILD_NUMBER/g")
+ | sed -e "s/<hw_type>/$hw_type/g" \
+ -e "s/@hw_type@/$hw_type/g" \
+ -e "s/<build_num>/$BUILD_NUMBER/g" \
+ -e "s/@build_num@/$BUILD_NUMBER/g")
if echo "$results_id" | grep -q "\.\."; then
echo "ERROR: results_id should not escape /home/tcwg-benchmark/results* hierarchy; do not use \"..\""
exit 1
diff --git a/tcwg_bmk-build.sh b/tcwg_bmk-build.sh
index 59e3ca93..5ce37b5f 100755
--- a/tcwg_bmk-build.sh
+++ b/tcwg_bmk-build.sh
@@ -50,7 +50,7 @@ case "${rr[target]}" in
*) hw=tx1 ;;
esac
-results_id="$hw/${rr[ci_project]}/${rr[ci_config]}-<build_num>"
+results_id="$hw/${rr[ci_project]}/${rr[ci_config]}-@build_num@"
if $verbose2; then set -x; fi
@@ -134,7 +134,7 @@ benchmark ()
| grep SUCCESS \
| sed -e "s/.*#\([0-9]\+\)-.*/\1/")
- results_id=$(echo "$results_id" | sed -e "s/<build_num>/$build_num/g")
+ results_id=$(echo "$results_id" | sed -e "s/@build_num@/$build_num/g")
echo "$results_id" > "${rr[top_artifacts]}/results_id"
)
}