diff options
author | Tobias Johansson <tobias.j.e.johansson@gmail.com> | 2016-03-06 12:31:29 +0100 |
---|---|---|
committer | Tobias Johansson <tobias.j.e.johansson@gmail.com> | 2016-03-06 13:39:07 +0100 |
commit | 913cc3f6f9f352535a5e82bb6034aa9002cadb9d (patch) | |
tree | 5f7700bbdf436d41057f462f9eae8d9ae0238331 | |
parent | f4fa7f48e6a09785eda7c24542e7e3eb0235b33e (diff) | |
download | cbt-913cc3f6f9f352535a5e82bb6034aa9002cadb9d.tar.gz cbt-913cc3f6f9f352535a5e82bb6034aa9002cadb9d.tar.bz2 cbt-913cc3f6f9f352535a5e82bb6034aa9002cadb9d.zip |
Check that javac version >= 1.8
-rwxr-xr-x | cbt | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -15,6 +15,13 @@ if [ ! $javac_installed -eq 0 ]; then echo "You need to install javac! CBT needs it to bootstrap from Java sources into Scala." 2>&1 exit 1 fi +javac_version=$(javac -version 2>&1 | cut -d ' ' -f 2) +javac_version_minor=$(echo -n $javac_version | cut -d '.' -f 2) +if [ ! "$javac_version_minor" -ge "8" ]; then + echo "You need to install javac version 1.8 or greater! CBT currently relies on Java 8." 2>&1 + echo "Current javac version is $javac_version" 2>&1 + exit 1 +fi which ng 2>&1 > /dev/null ng_installed=$? which ng-server 2>&1 > /dev/null |