Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Blocker
-
Resolution: Fixed
-
Affects Version/s: 1.1-rc-3
-
Fix Version/s: 1.5
-
Component/s: groovy-jdk
-
Labels:None
Description
The following Gant script fails with the message:
Enter HTTP proxy host [localhost]: [localhost]
Enter HTTP proxy port [80]: [80]
Failed to read input from Console.
import org.codehaus.groovy.grails.commons.GrailsClassUtils as GCU grailsHome = Ant.project.properties."environment.GRAILS_HOME" includeTargets << new File ( "${grailsHome}/scripts/Init.groovy" ) target('default': "The description of the script goes here!") { doStuff() } target(doStuff: "The implementation task") { def proxyHost = System.getProperty("http.proxyHost") ? System.getProperty("http.proxyHost") : 'localhost' def proxyPort = System.getProperty("http.proxyPort") ? System.getProperty("http.proxyPort") : '80' def proxyUser = System.getProperty("http.proxyUserName") ? System.getProperty("http.proxyUserName") : '' def proxyPassword = System.getProperty("http.proxyPassword") ? System.getProperty("http.proxyPassword") : '' Ant.input(addProperty:"proxy.host", message:"Enter HTTP proxy host [${proxyHost}]: ",defaultvalue:proxyHost) Ant.input(addProperty:"proxy.port", message:"Enter HTTP proxy port [${proxyPort}]: ",defaultvalue:proxyPort) Ant.input(addProperty:"proxy.user", message:"Enter HTTP proxy username [${proxyUser}]: ",defaultvalue:proxyUser) Ant.input(addProperty:"proxy.password", message:"Enter HTTP proxy password [${proxyPassword}]: ",defaultvalue:proxyPassword) }
Issue Links
- is depended upon by
-
GRAILS-1979
"grails set-proxy" in 1.0 RC2 terminates prematurely
-
Thought it was a Gant problem but the following AntBuilder script exhibits the same problem:
Caught: : Failed to read input from Console.
at test.run(test.groovy:3)
at test.main(test.groovy)