mp_loki
mp_loki

Reputation: 1048

Grails 2.4.3 does not work on mac os x

I am using grails installation on mac os x v.10.9.5. I used to have grails 2.4.2 installation and it was working fine. As I tried to install 2.4.3 version (both through gvm and manually, by unpacking archive and setting PATH and GRAILS_HOME variables), the installation seems to be ok, but when running "grails" command from terminal it had no effect, just the behaviour similar to "clear" terminal command. No output or error message was provided.

Does anyone have ideas what could be wrong with environment or installation? Or at least where can I find logs from running "grails" command?

Any help is appreciated. Thank you

Upvotes: 2

Views: 1667

Answers (2)

dammina
dammina

Reputation: 655

I had the same issue and in my case the error was due to $JAVA_HOME environment variable. For grails to execute properly java is a prerequisite. Therefore you should check whether you have added java to your class path before executing grails.

To verify this you should run, java -version before grails commands such as grails -version

Upvotes: 1

jeffrey
jeffrey

Reputation: 248

Find your grails installation, then check its shell wrapper at bin/grails. Suppose it contains the following lines :

#!/bin/sh
trap "reset" EXIT
trap "reset" INT
trap "reset" TERM

DIRNAME=`dirname "$0"`
. "$DIRNAME/startGrails"

startGrails org.codehaus.groovy.grails.cli.GrailsScriptRunner "$@"

Use your favourite text editor to edit the file, add # in front of the traps to comment those lines out.

#trap "reset" EXIT
#trap "reset" INT
#trap "reset" TERM

Then execute any grails commands like grails -version, check the console output to find the real reason that grails did not run. Good luck.

Upvotes: 5

Related Questions