feat(write_files): Set default permissions to 0644

Fix #26
fix(write_files): Create directories with mode 0755

Fix #28