RE: Groovy on Windows 11, unable to resolve class

2024-01-19 Thread Bob Brown
*I* find that the best way to handle the "spaces in path" problem on windows is 
to avoid it by using the '8dot3' version of a file/dir name:

===
C:\>dir /x
 Volume in drive C has no label.
 Volume Serial Number is D215-0F37

 Directory of C:\

31/10/2023  08:01 AM   BIN
22/11/2023  06:58 PM   Dell
23/12/2023  09:44 PM   DEV
20/01/2024  10:41 AM   DEVTOOLS
13/01/2024  10:43 AM   Java
31/10/2023  07:42 AM   LIB
19/01/2024  09:23 AM  PROGRA~1 Program Files
30/12/2023  10:20 AM  PROGRA~2 Program Files (x86)
23/10/2023  07:24 PM   Users
10/01/2024  08:11 PM   Windows
24/11/2023  07:24 PM   WSL2
   0 File(s)  0 bytes
  11 Dir(s)  736,955,072,512 bytes free

C:\>set GROOVY_HOME=C:\PROGRA~2\Groovy

C:\>
===


Of course, this relies on the filesystem actually generating these alternative 
filenames, not all do. To determine your situation:

=== (run as administrator):
C:\>fsutil 8dot3name query c:
The volume state is: 0 (8dot3 name creation is ENABLED)
The registry state is: 2 (Per volume setting - the default)

Based on the above settings, 8dot3 name creation is ENABLED on "c:"

C:\>
===

Ref: 
https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/fsutil-8dot3name

HTH

BOB


-Original Message-
From: Paul King  
Sent: Friday, January 19, 2024 10:00 PM
To: users@groovy.apache.org
Subject: Re: Groovy on Windows 11, unable to resolve class

Or do you already have GROOVY_HOME set but to somewhere else?

<https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail>
Virus-free.www.avast.com
<https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail>
<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>

On Thu, Jan 18, 2024 at 9:58 PM Søren Berg Glasius  wrote:
>
> I'm not at windows user myself, but seems to remember, that is most likely 
> because of the spaces in "C:\Program Files (x86)\Groovy\"
>
> Den tors. 18. jan. 2024 kl. 11.47 skrev poubelle zenira 
> :
>>
>> I just installed groovy 4 on windows from the installer.
>>
>> When running groovysh I get:
>> "ClassNotFoundException: org.apache.groovy.groovysh.Main"
>>
>> And when trying to import a groovy, i get an "unable to resolve 
>> class" error
>>
>> I checked the windows path,
>> GROOVY_HOME is set to C:\Program Files (x86)\Groovy\, where groovy is 
>> installed (I leaved the default installation parameters) And I manually 
>> added %GROOVY_HOME%\bin to the path because it was not there.
>>
>> But it still doesn't work.
>
>
>
> --
>
> Med venlig hilsen,
> Søren Berg Glasius
>
> Hedevej 1, Gl. Rye, 8680 Ry
> Mobile: +45 40 44 91 88
> --- Press ESC once to quit - twice to save the changes.


Re: Groovy on Windows 11, unable to resolve class

2024-01-19 Thread Paul King
Or do you already have GROOVY_HOME set but to somewhere else?


Virus-free.www.avast.com

<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>

On Thu, Jan 18, 2024 at 9:58 PM Søren Berg Glasius  wrote:
>
> I'm not at windows user myself, but seems to remember, that is most likely 
> because of the spaces in "C:\Program Files (x86)\Groovy\"
>
> Den tors. 18. jan. 2024 kl. 11.47 skrev poubelle zenira 
> :
>>
>> I just installed groovy 4 on windows from the installer.
>>
>> When running groovysh I get:
>> "ClassNotFoundException: org.apache.groovy.groovysh.Main"
>>
>> And when trying to import a groovy, i get an "unable to resolve class" error
>>
>> I checked the windows path,
>> GROOVY_HOME is set to C:\Program Files (x86)\Groovy\, where groovy is 
>> installed (I leaved the default installation parameters)
>> And I manually added %GROOVY_HOME%\bin to the path because it was not there.
>>
>> But it still doesn't work.
>
>
>
> --
>
> Med venlig hilsen,
> Søren Berg Glasius
>
> Hedevej 1, Gl. Rye, 8680 Ry
> Mobile: +45 40 44 91 88
> --- Press ESC once to quit - twice to save the changes.


Re: Groovy on Windows 11, unable to resolve class

2024-01-18 Thread Søren Berg Glasius
I'm not at windows user myself, but seems to remember, that is most likely
because of the spaces in "C:\Program Files (x86)\Groovy\"

Den tors. 18. jan. 2024 kl. 11.47 skrev poubelle zenira <
poubelle...@gmail.com>:

> I just installed groovy 4 on windows from the installer.
>
> When running groovysh I get:
> "ClassNotFoundException: org.apache.groovy.groovysh.Main"
>
> And when trying to import a groovy, i get an "unable to resolve class"
> error
>
> I checked the windows path,
> GROOVY_HOME is set to C:\Program Files (x86)\Groovy\, where groovy is
> installed (I leaved the default installation parameters)
> And I manually added %GROOVY_HOME%\bin to the path because it was not
> there.
>
> But it still doesn't work.
>


-- 

Med venlig hilsen,
Søren Berg Glasius

Hedevej 1, Gl. Rye, 8680 Ry
Mobile: +45 40 44 91 88
--- Press ESC once to quit - twice to save the changes.


Groovy on Windows 11, unable to resolve class

2024-01-18 Thread poubelle zenira
 I just installed groovy 4 on windows from the installer.

When running groovysh I get:
"ClassNotFoundException: org.apache.groovy.groovysh.Main"

And when trying to import a groovy, i get an "unable to resolve class" error

I checked the windows path,
GROOVY_HOME is set to C:\Program Files (x86)\Groovy\, where groovy is
installed (I leaved the default installation parameters)
And I manually added %GROOVY_HOME%\bin to the path because it was not there.

But it still doesn't work.