Export to files using UTF-8

Fixes #162
Changelog & version bump to 1.7.22
Merge pull request #163 from maebert/fix-162

Fix 162