Hiding Ant Input

I've got an ant build script that I've added a new deployment target to. I've got it using scp to deploy to a remote host, and I have everything working the way I want, except when IntelliJ pops open the dialog for my Input task (wherein, I ask for the password), the Input dialog is not aware it's a password, and should be doing **** instead of "the password in plain text, for all to see".

I've tried looking for a task in Ant like 'secretInput' or 'password', but can't find it. Is there a trick in IntelliJ ?

My task looks like this:


and I need the "user password" task to prompt for input, but mask the input.


Comment actions Permalink

On Fri, 08 Aug 2008 01:55:40 +0000, Mike Fourier wrote:

[How to have an Ant script run from IDEA prompt for a password without
echoing the plain text?]

Not IDEA-specific, but if you're using Ant 1.7 then you can create your
own implementation of the org.apache.tools.ant.input.InputHandler
interface and specify its use with a element nested in your ]]> element. Your InputHandler can show whatever UI it likes.


Mark Scott

Comment actions Permalink

Thanks Mark,

I managed to find someone who had done just that: com.jera.anttasks.Query


Please sign in to leave a comment.