Switching to Mr Pink's Java6 detector

This commit is contained in:
Viktor Klang 2012-06-11 22:53:45 +02:00
parent 36b040cfab
commit 649b9d5181

View file

@ -93,7 +93,7 @@ fi
declare -r version=$1 declare -r version=$1
declare -r publish_path="${release_server}:${release_path}" declare -r publish_path="${release_server}:${release_path}"
[[ `java -version 2>&1 | grep "java version" | awk '{print $3}' | tr -d \" | awk '{split($0, array, ".")} END{print array[2]}'` -eq 6 ]] || fail "Java version is not 1.6" [[ `java -version 2>&1 | head -1 | cut -d ' ' -f3 | cut -d '.' -f2` -eq 6 ]] || fail "Java version is not 1.6"
# check for a git command # check for a git command
type -P git &> /dev/null || fail "git command not found" type -P git &> /dev/null || fail "git command not found"