You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kylin.apache.org by li...@apache.org on 2017/01/12 04:09:46 UTC

[14/50] [abbrv] kylin git commit: KYLIN-2362 Unify shell interpreter in scripts

KYLIN-2362 Unify shell interpreter in scripts

Signed-off-by: lidongsjtu <li...@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/kylin/repo
Commit: http://git-wip-us.apache.org/repos/asf/kylin/commit/fbacb71e
Tree: http://git-wip-us.apache.org/repos/asf/kylin/tree/fbacb71e
Diff: http://git-wip-us.apache.org/repos/asf/kylin/diff/fbacb71e

Branch: refs/heads/master-cdh5.7
Commit: fbacb71ed7aa982b04dc4556c253a9bcfee576fa
Parents: 40ede31
Author: etherge <et...@163.com>
Authored: Fri Jan 6 14:18:47 2017 +0800
Committer: lidongsjtu <li...@apache.org>
Committed: Fri Jan 6 15:53:52 2017 +0800

----------------------------------------------------------------------
 build/bin/check-env.sh            | 2 +-
 build/bin/find-hive-dependency.sh | 4 ++--
 build/bin/kylin.sh                | 2 +-
 build/bin/sample.sh               | 8 ++++----
 4 files changed, 8 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kylin/blob/fbacb71e/build/bin/check-env.sh
----------------------------------------------------------------------
diff --git a/build/bin/check-env.sh b/build/bin/check-env.sh
index 9cd8a64..a4003c9 100644
--- a/build/bin/check-env.sh
+++ b/build/bin/check-env.sh
@@ -41,7 +41,7 @@ then
     quit "Please make sure the user has the privilege to run hadoop shell"
 fi
 
-WORKING_DIR=`sh $KYLIN_HOME/bin/get-properties.sh kylin.env.hdfs-working-dir`
+WORKING_DIR=`bash $KYLIN_HOME/bin/get-properties.sh kylin.env.hdfs-working-dir`
 hadoop fs -mkdir -p $WORKING_DIR
 if [ $? != 0 ]
 then

http://git-wip-us.apache.org/repos/asf/kylin/blob/fbacb71e/build/bin/find-hive-dependency.sh
----------------------------------------------------------------------
diff --git a/build/bin/find-hive-dependency.sh b/build/bin/find-hive-dependency.sh
index fe9e0a3..453a35a 100644
--- a/build/bin/find-hive-dependency.sh
+++ b/build/bin/find-hive-dependency.sh
@@ -19,13 +19,13 @@
 
 source $(cd -P -- "$(dirname -- "$0")" && pwd -P)/header.sh
 
-client_mode=`sh ${KYLIN_HOME}/bin/get-properties.sh kylin.source.hive.client`
+client_mode=`bash ${KYLIN_HOME}/bin/get-properties.sh kylin.source.hive.client`
 hive_env=
 
 echo Retrieving hive dependency...
 if [ "${client_mode}" == "beeline" ]
 then
-    beeline_params=`sh ${KYLIN_HOME}/bin/get-properties.sh kylin.source.hive.beeline-params`
+    beeline_params=`bash ${KYLIN_HOME}/bin/get-properties.sh kylin.source.hive.beeline-params`
     hive_env=`beeline ${beeline_params} --outputformat=dsv -e set 2>&1 | grep 'env:CLASSPATH' `
 else
     hive_env=`hive -e set 2>&1 | grep 'env:CLASSPATH'`

http://git-wip-us.apache.org/repos/asf/kylin/blob/fbacb71e/build/bin/kylin.sh
----------------------------------------------------------------------
diff --git a/build/bin/kylin.sh b/build/bin/kylin.sh
index fca1e5c..0cdbbc6 100644
--- a/build/bin/kylin.sh
+++ b/build/bin/kylin.sh
@@ -73,7 +73,7 @@ then
     #In this way we no longer need to explicitly configure hadoop/hbase related classpath for tomcat,
     #hbase command will do all the dirty tasks for us:
 
-    spring_profile=`sh ${dir}/get-properties.sh kylin.security.profile`
+    spring_profile=`bash ${dir}/get-properties.sh kylin.security.profile`
     if [ -z "$spring_profile" ]
     then
         quit 'please set kylin.security.profile in kylin.properties, options are: testing, ldap, saml.'

http://git-wip-us.apache.org/repos/asf/kylin/blob/fbacb71e/build/bin/sample.sh
----------------------------------------------------------------------
diff --git a/build/bin/sample.sh b/build/bin/sample.sh
index 1397034..1363a5d 100644
--- a/build/bin/sample.sh
+++ b/build/bin/sample.sh
@@ -29,10 +29,10 @@ echo "Loading sample data into HDFS tmp path: /tmp/kylin/sample_cube/data"
 hadoop fs -mkdir -p /tmp/kylin/sample_cube/data
 hadoop fs -put * /tmp/kylin/sample_cube/data/
 
-hive_client_mode=`sh ${KYLIN_HOME}/bin/get-properties.sh kylin.source.hive.client`
+hive_client_mode=`bash ${KYLIN_HOME}/bin/get-properties.sh kylin.source.hive.client`
 if [ "${hive_client_mode}" == "beeline" ]
 then
-    beeline_params=`sh ${KYLIN_HOME}/bin/get-properties.sh kylin.source.hive.beeline-params`
+    beeline_params=`bash ${KYLIN_HOME}/bin/get-properties.sh kylin.source.hive.beeline-params`
     beeline ${beeline_params} -f ${KYLIN_HOME}/sample_cube/create_sample_tables.sql  || { exit 1; }
 else
     hive -f ${KYLIN_HOME}/sample_cube/create_sample_tables.sql  || { exit 1; }
@@ -42,8 +42,8 @@ echo "Sample hive tables are created successfully; Going to create sample cube..
 hadoop fs -rm -r /tmp/kylin/sample_cube
 
 # set engine type and storage type to cube desc
-default_engine_type=`sh ${KYLIN_HOME}/bin/get-properties.sh kylin.engine.default`
-default_storage_type=`sh ${KYLIN_HOME}/bin/get-properties.sh kylin.storage.default`
+default_engine_type=`bash ${KYLIN_HOME}/bin/get-properties.sh kylin.engine.default`
+default_storage_type=`bash ${KYLIN_HOME}/bin/get-properties.sh kylin.storage.default`
 if [ -z "$default_engine_type" ]; then
     default_engine_type=2
     default_storage_type=2