Suppose patch tell me
Assume -R? [n]
in already patched source Is there a way to say n no automatically? I can use yes n|patch but i prefer a more clean solution
Look at the -f (--force) and -N (--forward) options, assuming that you use GNU patch. They may do what you want or may be insufficient with particular patches. If they are insufficient, you can use the expect utility, which can answer depending on the question.