resolves #907 write to file by default if input is file

- write to file by default if input is file
- use to_file option to control whether file is written instead of in_place
- prevent input file from being overwritten
Merge pull request #910 from mojavelinux/issue-907

resolves #907 write to file by default if input is file