Ensure pragma checksum is prepended to generated file

Fixes #160
Why do you need to seek at all?  You go from bytes -> Utf8 , just read bytes, use them for checksum, then convert them to string.