Update header comments on both script and library

Updated the header comments to be homogenous and include author, dates
and license info.
Refactor secrets.rb duplicated code

The encryption and decryption routines in secrets.rb were basically the
exact same thing with a little bit different setup and teardown.
So it was pretty easy to refactor them into a strip_filename method and
an update_file method which reduce duplication.
Added a simple notice not to close terminal

If you close terminal while editing a file in update mode, it never
re-encrypts because it didn't launch a separate process or anything.