I've created a Bash script to copy a WordPress plugin to every WordPress installation on our server:

http://pastebin.com/f191ee2b9

On line 13, the cp command uses the -n flag to not overwrite existing files. I'd prefer to use the -i flag so that I'm prompted whether I want to overwrite existing files. However, the -i flag doesn't work in the xargs loop. It simply loops through each file and answers with the default "no" for each prompt.

Can I make the xargs/cp loop actually ask me whether I want to overwrite existing files?

Richard


_______________________________________________

UPHPU mailing list
[email protected]
http://uphpu.org/mailman/listinfo/uphpu
IRC: #uphpu on irc.freenode.net

Reply via email to