Hi,

We now handle passing the clients stdin to the build daemon. This means we have 
to do some swapping around of System.in. I can see that at some point someone 
is going to want to do their own System.in swapping and this is going to break 
our strategy.

A case might be the use of some library that a user wants to integrate that 
insists on reading from stdin and they want to pipe their own data (say from a 
file) to this utility. The first thing they will reach for is System.setIn().

What we could do is provide a project method that takes an InputStream and a 
Closure that we make work with our strategy. e.g.

withInput(new FileInputStream(file("input-for-library")) {
        new SomeLibrary().readStdin()
}

It's an edge case to be sure, but it seems like we should make it work now 
while adding stdin support to the daemon.

-- 
Luke Daley
Principal Engineer, Gradleware 
http://gradleware.com


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to