Set file permissions and other tweaks.