Add attribute to control which substitutions are performed on docinfo files

Resolves #405
Oh boy, this is not Java or C, it can be written much elegantly in Ruby… :crying_cat_face: :crying_cat_face: