Running a groovy script created in STS(Spring Tool Suite) using the command line
        Posted  
        
            by 
                user1811107
            
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by user1811107
        
        
        
        Published on 2012-11-17T04:27:13Z
        Indexed on 
            2012/11/20
            5:00 UTC
        
        
        Read the original article
        Hit count: 199
        
I have used the STS(Spring Tool Suite) to create a compiled groovy script which exists as a file on windows called Test.class. I am able to right click on the file in STS and execute it which works well.
However - I want to be able to execute the script on the windows command line, so far I have tried various ways but have not been successful. I have tried the following...
java -cp C:\Users\MyName\springsource\sts-> 3.1.0.RELEASE\plugins\org.codehaus.grails.bundle_2.1.1\content\lib\ org.codehaus.groovy\groovy-all\jars\groovy-all-1.8.8.jar Test.class
But that does not work it gives me an error --> Error: Could not find or load main class Test.class
Any Pointers?
© Stack Overflow or respective owner