Add overwrite option to update source files in-place

Ignore the earlier pull request. I had some time to write this up cleanly and update the readme.

The impact on performance is negligible since the input and output are already computed as per default behavior. I just do an equality check before overwriting the source.