KYLIN-1679 Use full-match pattern to get kylin properties in shell scripts
Project: http://git-wip-us.apache.org/repos/asf/kylin/repo Commit: http://git-wip-us.apache.org/repos/asf/kylin/commit/baac10b0 Tree: http://git-wip-us.apache.org/repos/asf/kylin/tree/baac10b0 Diff: http://git-wip-us.apache.org/repos/asf/kylin/diff/baac10b0 Branch: refs/heads/stream_m1 Commit: baac10b037fc761690cc839e226f3f2c9ecc97a4 Parents: b70ad40 Author: zkld123 <zkld...@sjtu.edu.cn> Authored: Thu Jun 16 16:18:21 2016 +0800 Committer: zkld123 <zkld...@sjtu.edu.cn> Committed: Thu Jun 16 16:18:21 2016 +0800 ---------------------------------------------------------------------- build/bin/get-properties.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/kylin/blob/baac10b0/build/bin/get-properties.sh ---------------------------------------------------------------------- diff --git a/build/bin/get-properties.sh b/build/bin/get-properties.sh index 3151ad6..a53de6b 100755 --- a/build/bin/get-properties.sh +++ b/build/bin/get-properties.sh @@ -25,7 +25,7 @@ fi IFS=$'\n' result= -for i in `cat ${KYLIN_HOME}/conf/kylin.properties|grep -w "$1"| grep -v '^#' |awk -F= '{ n = index($0,"="); print substr($0,n+1)}' | cut -c 1-` +for i in `cat ${KYLIN_HOME}/conf/kylin.properties | grep -w "^$1" | grep -v '^#' | awk -F= '{ n = index($0,"="); print substr($0,n+1)}' | cut -c 1-` do : result=$i