sourcegraph/rwvfs — pull request #2 by proglottis (2014-09-26 05:01:16+00:00)
Title: Allow permissions to be set on OS FileSystem

Adds a new OSPerm function to create a FileSystem that uses specified creation permissions.

Also sets the default directory permission to 0755 to be more consistent with the default os.Create permission. I backed away from setting 0777 since everywhere suggests it is bad practice. I did some testing and couldn't actually create a directory with 0777 permissions - I think this is the umask that os.Create references in it's comment. So not too sure there.

It shouldn't break any existing apps using the library - but if you'd prefer not to add more attributes to the osFS struct then I can redo my pull request with a whole new type (and some code duplication).