I'm trying to find a Pry Deubgger equivalent on Groovy.
I found a good enough project named groovy-debugger and updated it's dependencies to run against groovy 2.3.1 which comes with Grails 2.4.0.
If I open a groovysh just a blinking cursor will be shown which does not accept any input.
I tried to get the input stream and output stream of a current grails console, but it does not help.
Anyone can help me setup my beloved REPL-driven development environment on Groovy.
So using Grails 2.4.0 I created a new project and started the shell with grails shell and it was able to accept input with no problem. This is with Mac OS X. What operating system are you running?
Related
I am working on Windows. I am trying to use Grails 3.0.9 version. Previously, I used Grails 2.4.2, everything worked well.
After Downloading and setting windows environment for 3.0.9 of Grails, I typed 'grails help' or 'grails create-app test' on Windows cmd.
It always tell 'Error: Could not find or load main class org.codehaus.groovy.grails.cli.support.GrailsStarter'
Then I try to use 3.0.8, it told the same error. But if I switch to use 2.4.2, it works normally.
Ps. On Grails 3.0.9, I use jdk1.8.0_65.
What I did wrong or what I missed for setting for a new version of Grails.
Thanks.
I Had exactly the same problem. You could try that:
Open a new CMD window and print your variables (PATH, GRAILS_HOME) if set.
Sometimes my variables still referenced my Grails 2.3.7 library and not 3.0.8 which I wanted to use.
That was happening on Windows 10 to me. After a few restarts from CMD all went well. Maybe System variables are somehow cached and not set immediately.
I would recommend using gvm on windows, its a tool to install, switch grails very quickly using windows powershell
its now called sdkman http://sdkman.io/
if your installing on mac or or unix like os
https://github.com/flofreud/posh-gvm has a good tutorial on installing for windows
gvm install grails 3.0.9 , you can set it as the default by saying yes at the end or
gvm use grails 3.0.9
gvm list grails to see what other versions of grails are available to install.
then type grails -version to see what version is installed and test out grails
your grails create-app should then work
I am trying to setup aNimble on Windows following this article.
I have setup the Java and MySQL (xampp) on Windows and both are working properly.
Now, as the final step I need to execute
grails prod execute-database-scripts-all
but I am getting cannot find the specified path. Even when I type grails only I get the same error. I have zero experience in Grails, but it seems that I need to install Grails first on the PC. Until I do this, I want to know is there anything else that I need to do this to successfully execute this command.
What are the three portions of this command grails, prod and execute-database-scripts-all
This error means that Windows is unable to find grails executable anywhere it looks (in any paths specified in PATH system property) when you typing grails command. You may have to follow this guide in order to install grails application framework properly in your system (also, make sure you are installing a correct version of grails compatible with your distribution of aNimble) and then retry.
Grails is a web application framework and which provides a set of tools to develop, build and run web applications like aNimble, prod is a command line option for grails telling it to run in a production mode and execute-database-scripts-all is aNimble-specific command to initialize it's database.
I'm trying to get my feet wet with grails, so I'm following a tutorial to get going with a sample project. I downloaded grails 2.3.2, added the environment variables for the command prompt commands, and successfully created a project by using >grails create-app teamwork. Calling >grails run-app after changing to the project directory successfully downloads all requisites, but then I get . I know that this exception doesn't reveal much, but do you guys have any ideas on why? I am running command prompt in admin mode, if that means anything.
Try not forking the JVM in BuildConfig.groovy, if I recall correctly. If that works, then check the JIRA issues for Grails 2.3.2.
I have recently started to work with grails. I was able to create applications and generate stuff. Yesterday I wanted to resume my work, after a little break and ran into the following error, when trying to create a new project:
Command terminated with an exception:
org.grails.ide.eclipse.longrunning.client.GrailsProcessDiedException: Grails process died
(see details for partial output)
Grails process died
------System.out:-----------
------System.err:-----------
This error only occurs when I use the SpringSourceTool, if I try using the command line it works fine. My first reaction was to change the java version from 1.8 to 1.7, but that didn't help. My environment variables look like this (I am running Fedora Linux 19)
JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.0.x86_64
GRAILS_HOME=/home/peer/grails/grails-2.3.0
They are also included in the PATH variable.
Can anybody help? Thanks, Peer
This is a known issue in STS:
https://issuetracker.springsource.com/browse/STS-3277
A work-around is provided in the link.
For anyone pulling their hair out trying to create a grails project using the STS extension for Grails, here is my setup and following is what I did to get it working:
-- OSX 10.8.4 Build 12E3067 --
-- STS Version 3.4.0 --
-- Grails 2.3.3 (installed separately to STS) --
Fresh installed STS 3.4.0
I *de*selected the Preferences/Groovy/Compiler/Enable checking for mismatches between
project and workspace Groovy compiler levels
I ONLY selected the Grails Support option when installing the extensions (nothing else)
Restart STS 3.4.0 (i.e. restart eclipse)
I then pointed my Grails project to my existing Grails 2.3.3 installation
Make sure that the environment variable GRAILS_HOME is set and exported in the same
shell from which you invoke STS otherwise you will get a process termination error in
Eclipse (STS)
This worked.
On Ubuntu 12.04, when I run grails run-app, after stopping the app, the terminal cursor doesn't move when typing, and no text appears. I can still type commands, but I have to either do it blindly or use reset to reset the terminal. Has anyone else seen this behavior? Ive tested in grails 2.0.1, 2.0.4, 2.1.2 and 2.2.1. The same behavior happens for all. Any suggestions?
grails --plain-output run-app should disable the use of ANSI colour codes, which might help, depending on which terminal program you're using.