Skip to content

Commit

Permalink
Merge branch 'master' of github.com:filodb/FiloDB
Browse files Browse the repository at this point in the history
  • Loading branch information
Evan Chan committed Nov 15, 2016
2 parents 7d1d2ca + 71cacad commit 194d43e
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 14 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -587,6 +587,10 @@ Query/export some columns:

Version 0.4 is the stable, latest released version. It has been tested on a cluster for a different variety of schemas, has a stable data model and ingestion, and features a huge number of improvements over the previous version.

### Upcoming version 0.5 changes:

* creating a function for checking java and another to check sbt (@jenaiz)

### Version 0.4 change list:

* Defaults to Spark 1.6.1
Expand Down
36 changes: 22 additions & 14 deletions filo-cli
Original file line number Diff line number Diff line change
Expand Up @@ -6,28 +6,36 @@ FILO_VERSION=$(cat version.sbt | sed -e 's/.*"\(.*\)"/\1/g')
CLI_FILE=`pwd`"/cli/target/scala-$SCALA_VERSION/filo-cli-$FILO_VERSION"

function isJava8(){
if [[ "$JAVA" ]]; then
version=$("$JAVA" -version 2>&1 | awk -F '"' '/version/ {print $2}')
if [[ "$version" < "1.8" ]]; then
echo "FiloDB requires Java JDK 1.8 and the current version is $version. Please upgrade to continue."
if [[ "$JAVA" ]]; then
version=$("$JAVA" -version 2>&1 | awk -F '"' '/version/ {print $2}')
if [[ "$version" < "1.8" ]]; then
echo "FiloDB requires Java JDK 1.8 and the current version is $version. Please upgrade to continue."
exit
fi
fi
}

function check_java {
JAVA=$(type -p java)
if [ -z "$JAVA" ]; then
echo "Failed to find Java in PATH. Please install Java JDK 1.8"
exit
fi
fi
}

JAVA=$(type -p java)
if [ -z "$JAVA" ]; then
echo "Failed to find Java in PATH. Please install Java JDK 1.8"
exit
fi
function check_sbt {
if [ -z $1 ]; then
echo "Failed to find SBT in PATH. Please install SBT"
exit
fi
}

isJava8
check_java

SBT=$(type -p sbt)
if [ -z "$SBT" ]; then
echo "Failed to find SBT in PATH. Please install SBT"
exit
fi

check_sbt $SBT

if [ ! -f "$CLI_FILE" ];then
# run assembly if file doesn't exist
Expand Down

0 comments on commit 194d43e

Please sign in to comment.