Auto answer option in scripting.

[LEFT]Hi masters,

How to get auto answer option in scripting. for example in my script i uses the gpg command , in that beginning it will ask

passpharse : ( in that i need to type my passpharase)

and once i typed it will ask

Use this key anyway? ( for that answer will be yes)

for this two questions i need to answer while running the script. how to do this possible, kindly guide me to solve this thread.
[/LEFT]

Check the following gpg options:

--command-fd <FD>
--passphrase-fd <FD>

---------- Post updated at 16:27 ---------- Previous update was at 16:26 ----------

The links below too:
-----> stdout - Suppress GPG "Reading passphrase from file descriptor 0" message - Server Fault
-----> Decrypting Files Automatically | GnuPG | users