apache / apache/grails-intellij-plugin

"Start Grails Console in Interactive Mode" fails

Open
#159 0 comments 0 reactions 0 assignees View on GitHub
bug imported-from-youtrack
Dominant language
Java
Stars
17
Forks
4
Avg merge
5d 15h
Merged PRs (30d)
4

Description

This report relates to IU-135-698; win8.1 all latest patches.

My Java SDK Home path set in the IntelliJ settings is:

R:\Program Files\Java\jdk1.6.0_45

If I press ^-Alt-G, then the "Start Grails Console in Interactive Mode", I get a cmd console containing:
```
ERROR: JAVA_HOME is set to an invalid directory: R:/Program Files/Java/jdk1.6.0_
45

Please set the JAVA_HOME variable in your environment to match the
location of your Java installation.
```
Note the substitution of win-style '\' for *nix-style '/' path separators. I assume that this is the problem...

In the same window, I can do:
```
X:\DEVELOPMENT\IOS23\trunk>dir %JAVA_HOME%
Parameter format not correct - "Program".

X:\DEVELOPMENT\IOS23\trunk>dir "%JAVA_HOME%"
Volume in drive R is REST
Volume Serial Number is 5A9C-D6FE

Directory of R:\Program Files\Java\jdk1.6.0_45

26/01/2014 04:40 PM .
26/01/2014 04:40 PM ..
26/01/2014 04:40 PM bin
01/04/2013 04:24 PM 3,409 COPYRIGHT
26/01/2014 04:40 PM include
26/01/2014 04:40 PM jre
26/01/2014 04:40 PM lib
26/01/2014 04:40 PM 41 LICENSE
26/01/2014 04:40 PM 125 README.html
01/04/2013 04:26 PM 19,694,045 src.zip
26/01/2014 04:40 PM 172,117 THIRDPARTYLICENSEREADME.txt
5 File(s) 19,869,737 bytes
6 Dir(s) 454,866,485,248 bytes free

X:\DEVELOPMENT\IOS23\trunk>
```
A work-around MIGHT be to use R:\Progra~1\Java\jdk1.6.0_45, but the settings GUI will not allow one to specify this by hand.

For reference:
```
X:\DEVELOPMENT\IOS23\trunk>dir /x r:
Volume in drive R is REST
Volume Serial Number is 5A9C-D6FE

Directory of R:\

10/04/2014 11:44 AM BIN
15/04/2014 08:27 PM DEVELO~1 DEVELOPMENT
15/04/2014 02:13 PM DEVTOOLS
22/10/2013 02:15 PM PROGRA~1 Program Files
11/04/2014 10:21 PM PROGRA~2 Program Files (x86)
15/11/2013 08:17 PM RECORD~1 Recorded TV
03/04/2014 09:03 PM TEMP
30/10/2012 08:54 AM Users
0 File(s) 0 bytes
8 Dir(s) 454,866,419,712 bytes free

X:\DEVELOPMENT\IOS23\trunk>
```
If I bring up a cmd window outside of IntelliJ, I can do:
```
Microsoft Windows [Version 6.3.9600]
(c) 2013 Microsoft Corporation. All rights reserved.

C:\Users\>echo %JAVA_HOME%
%JAVA_HOME%

C:\Users\>
```
I always keep JAVA_HOME unset on my PC so that my path is uncluttered. I set is when needed, as needed.

---

*Imported from [IDEA-124029](https://youtrack.jetbrains.com/issue/IDEA-124029) · Type: Bug · Votes: 4*
*Comments, attachments, dates and reporter are not part of the export — follow the link above for the full history.*

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the Windows 8.1 failure through “Start Grails Console in Interactive Mode” using the ^-Alt-G shortcut and the configured Java SDK path. Trace how that entry point passes the IntelliJ Java SDK path to the command console; done means the console starts successfully with paths containing spaces and the existing SDK configuration.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
devtools
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.