Skip to content

GRAILS-8271 #117

Closed
wants to merge 4 commits into from
View
14 grails-resources/src/grails/home/bash/startGrails
@@ -36,11 +36,14 @@ earlyInit
# OS specific support (must be 'true' or 'false').
cygwin=false;
darwin=false;
+mingw=false;
case "`uname`" in
CYGWIN*)
cygwin=true
;;
-
+ MINGW*)
+ mingw=true
+ ;;
Darwin*)
darwin=true
;;
@@ -174,12 +177,19 @@ fi
# Fix the cygwin agent issue
AGENT_GRAILS_HOME=$GRAILS_HOME
+AGENT_LIBRARY="lib/com.springsource.springloaded/springloaded-core/jars/springloaded-core-@spring.loaded.version@.jar"
if $cygwin ; then
[ -n "$GRAILS_HOME" ] &&
AGENT_GRAILS_HOME=`cygpath --windows "$GRAILS_HOME"`
fi
+AGENT_GRAILS_JAR=$AGENT_GRAILS_HOME/$AGENT_LIBRARY
+# Fix the mingw bash shell not recognizing the agent jar path
+if $mingw ; then
+ [ -n "$AGENT_GRAILS_HOME" ] &&
+ AGENT_GRAILS_JAR=`cmd //C echo $AGENT_GRAILS_HOME/$AGENT_LIBRARY`
+fi
# Process JVM args
-AGENT_STRING="-javaagent:$AGENT_GRAILS_HOME/lib/com.springsource.springloaded/springloaded-core/jars/springloaded-core-@spring.loaded.version@.jar -noverify -Dspringloaded=profile=grails"
+AGENT_STRING="-javaagent:$AGENT_GRAILS_JAR -noverify -Dspringloaded=profile=grails"
CMD_LINE_ARGS=""
DISABLE_RELOADING=false
Something went wrong with that request. Please try again.