Closed ghost closed 7 years ago
This is strange, C-c C-s is undefined for me! It would of course help if I corrected my Groovy Mode Hook for the CC-Mode to standalone switch. :-)
C-c C-s works for me.
Groovy Shell (3.0.0-SNAPSHOT, JVM: 1.8.0_131)
Type ':help' or ':h' for help.
-------------------------------------------------------------------------------
groovy:000>
It appears that there is an assumption that you have set the GROOVY_HOME environment variable. Given there are so many places where package systems put things, I am not sure we can encode a default path. I guess we could pick up the user PATH and check along that. Let's mark this a bug, but there is a workaround.
I checked the help doc by C-h m
. It shows
C-c C-s run-groovy
I am new to Emacs, and don't know if I am on the right way - -
@russel you're right. I've set the "JAVA_HOME" and "GROOVY_HOME" in the config.fish
. And Emacs can't find the "GROOVY_HOME" if I start it from Launchpad. But Emacs can find them if I start it from terminal.
Do you know how emacs can read the environment variables if start from launchpad? I know this question should be asked to Emacs group/irc...
I have a putative solution to this to try and find groovysh on the user path even without GROOVY_PATH set. I shall take the risk of comitting this. This will trigger a MELPA rebuild, let's hope it works.
@NaixiaoZhang I think MELPA now has the new version of inf-groovy.el so an update and try again might show the fix works or doesn't.
@russel I just did an update. It has been fixed! For now, no matter the GROOVY_HOME is defined or not, launch from Launchpad or terminal can both work. Perfect!
Splendid. :-) Let's treat this as fixed for now and close this issue. If there are other problems let's do it via other issues.
When I run the script by "C-c C-s", I got an error:
/usr/local/opt/emacs-plus/Emacs.app/Contents/MacOS/Emacs: /bin/groovysh: No such file or directory
I install groovy by homebrew:
brew install groovy
Emacs version 26.0.50.