Do not generate invalid filenames. Fixes #814.

Turn invalid characters into underscores, remove leading dots and enforce
a maximum length. Should be fine on main file systems used by Windows, Mac OS
and Linux.
Thanks to @Avaris for helping to clean my code.
Output sources for translations as well.
Merge pull request #844 from Rogdham/pelican-import_invalid_characters

Do not generate invalid filenames. Fixes #814.
Merge pull request #846 from Rogdham/output_sources_translations

Output sources for translations as well.