############################
-function whichable()
-{
- to_find="$1"; shift
- which which &>/dev/null
- if [ $? -ne 0 ]; then
- # there is no which command here. we produce nothing due to this.
- echo
- fi
- echo $(which $to_find)
-}
+source $FEISTY_MEOW_SCRIPTS/core/functions.sh
+
+#function whichable()
+#{
+# to_find="$1"; shift
+# which which &>/dev/null
+# if [ $? -ne 0 ]; then
+# # there is no which command here. we produce nothing due to this.
+# echo
+# fi
+# echo $(which $to_find)
+#}
# this reports when we have totally failed to figure out where a folder
# is actually located on the machine.
if [ ! -d "$JAVA_HOME" ]; then
# first try a recent linux version.
- export JAVA_HOME=/usr/lib/jvm/java-6-sun/jre
+ export JAVA_HOME=/usr/lib/jvm/java-6-sun
fi
if [ ! -d "$JAVA_HOME" ]; then
# try an even more recent version.
- export JAVA_HOME=/usr/lib/jvm/java-7-oracle/jre
+ export JAVA_HOME=/usr/lib/jvm/java-7-oracle
fi
if [ ! -d "$JAVA_HOME" ]; then
JAVA_HOME="$(ls -d c:/tools/*jdk* 2>/dev/null)"
# intuit where we have our local eclipse.
if [ ! -d "$ECLIPSE_DIR" ]; then
- export ECLIPSE_DIR=/usr/local/eclipse_jee
+ export ECLIPSE_DIR=/usr/local/eclipse
fi
if [ ! -d "$ECLIPSE_DIR" ]; then
ECLIPSE_DIR=$HOME/eclipse
ECLIPSE_DIR="c:/tools/eclipse"
fi
if [ ! -d "$ECLIPSE_DIR" ]; then
- if [ ! -z "$(grep -i 'd:' /proc/mounts)" ]; then
+ if [ ! -z "$(grep -i 'd:' /proc/mounts 2>/dev/null)" ]; then
ECLIPSE_DIR="d:/tools/eclipse"
fi
fi
if [ ! -d "$ECLIPSE_DIR" ]; then
- if [ ! -z "$(grep -i 'e:' /proc/mounts)" ]; then
+ if [ ! -z "$(grep -i 'e:' /proc/mounts 2>/dev/null)" ]; then
ECLIPSE_DIR="e:/tools/eclipse"
fi
fi