aboutsummaryrefslogtreecommitdiff
path: root/cbt
diff options
context:
space:
mode:
authorChristopher Vogt <oss.nsp@cvogt.org>2016-04-26 10:58:02 -0400
committerChristopher Vogt <oss.nsp@cvogt.org>2016-04-28 13:33:20 -0400
commit51a353881de307aec8aa7c7f8eb8a83856132633 (patch)
treed0184c08bd6b46a9fb1201fcdfa398e11d229a04 /cbt
parent99f624011b3ae0e6088ffcb86dc414e3750ad5c9 (diff)
downloadcbt-51a353881de307aec8aa7c7f8eb8a83856132633.tar.gz
cbt-51a353881de307aec8aa7c7f8eb8a83856132633.tar.bz2
cbt-51a353881de307aec8aa7c7f8eb8a83856132633.zip
Do not check javac version (took > 0.1 seconds each time). This will lead to compile errors with java6, but those should be easy to google.
Diffstat (limited to 'cbt')
-rwxr-xr-xcbt22
1 files changed, 14 insertions, 8 deletions
diff --git a/cbt b/cbt
index a893dff..b83d7bc 100755
--- a/cbt
+++ b/cbt
@@ -47,16 +47,22 @@ log "Checking for dependencies" $*
which javac 2>&1 > /dev/null
javac_installed=$?
if [ ! $javac_installed -eq 0 ]; then
- echo "You need to install javac! CBT needs it to bootstrap from Java sources into Scala." 1>&2
- 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 "7" ]; then
- echo "You need to install javac version 1.7 or greater!" 2>&1
- echo "Current javac version is $javac_version" 2>&1
+ echo "You need to install javac 1.7 or later! CBT needs it to bootstrap from Java sources into Scala." 1>&2
exit 1
fi
+
+# log "cutting javac version" $*
+# javac_version=$(javac -version 2>&1) # e.g. "javac 1.8.0_u60"
+# javac_version_update=${javac_version/javac 1./} # e.g. "8.0_u60"
+# javac_version_minor_pointed=${javac_version_update%_*} # e.g. "8.0"
+# javac_version_minor=${javac_version_minor_pointed%.*} # e.g. "8"
+# log "cutting javac version done" $*
+# if [ ! "$javac_version_minor" -ge "7" ]; then
+# echo "You need to install javac version 1.7 or greater!" 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