I am comparing a couple of files with
vimdiff. There are some differences which I expect and which I'd like to get rid of. I know I can use:
:%s#from1#to1#g | %s#from2#to2#g | ...
to replace multiple expected differences at the same time. However, the 2nd substitution is only executed if the first succeeds; i.e.
from1 must be present in the file in order to replace
from2, too (I get
E486: Pattern not found: from1 and
from2 still exits). Can I specify multiple optional substitutions that all should be executed? I imagine some option for
| to behave like an
or instead of an
I would like to do this interactively because the expected differences differ among various files and I don't exactly know them in advance.