Repository navigation
Directory Permissions - Changed to use constants - #365
Conversation
Update to clean up the use of the 0755 value in the directory creation code. Also added comment about using the system's umask value in the future to better align created locations with that of the system's admin. Refactoring here should make updates easier in the future. NOTE: Not sure about the actual syntax of Go and its ability to keep uint32 values true given their assignment as constants.
Update lfs.go
|
This looks good, but I think the comment about future use of umask should be left out. The umask should already be honored when creating files and directories via Go code. That is, we ask for One formatting nit-pick, I think we'd rather see related consts blocked together. Also Go code will generally camel case the names rather than use all caps. You can find counterexamples such as const (
TempDirPerms = 0755
LocalMediaDirPerms = 0755
LocalLogDirPerms = 0755
)Thanks for the PR! |
Update based on comments received from initial pull request. Changes have been made and resubmitting.
There was a problem hiding this comment.
For now, there's no need to export these constants.
|
@thpang67 Thanks, just merged this. I have some Go feedback for you, under the assumption that you're pretty new to Go in general: We don't need to expose those values because they only matter to the internals of the I noticed that commit changed the spacing on the constants. I use the |
|
@technoweenie thanks for the information on the atom package. I have just started using atom and find it to be quite useful. I have added the go-plus package. Go is new to me. I am coming from many years of structured development and programming. Thanks again. |
I have updated the code to use constants in place of the 0755 along with a note about possibly using the umask of the system git-lfs is installed.