So which part of the behavior of --force is it that you don't want? Thanks, Andreas
2013/9/6 Bruce Korb <[email protected]>: > I am working in a situation where I have an automatable task that > includes patching a bunch of files. However, I do not know apriori > whether or not a particular patch has already been applied. > If I use the patch option, "--batch" it assumes (incorrectly) > that I want to reverse the patch. If I don't use the option, > then it reads from /dev/tty, making the whole thing interactive > instead of being an automated script. > > So there really need to be four modes of operation: > > force -- do the best you can > batch -- approximately the same, but apply in reverse if > it seems like it might be reversed > cautious-batch -- silently quit if anything looks awry > do *not* query /dev/tty for anything. > otherwise -- ask /dev/tty about anything unusual > > patch forthcoming, unless shouted down. >
