Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

os: document that FileMode permission bits are Unix bits #7075

Closed
gopherbot opened this issue Jan 7, 2014 · 8 comments
Closed

os: document that FileMode permission bits are Unix bits #7075

gopherbot opened this issue Jan 7, 2014 · 8 comments

Comments

@gopherbot
Copy link

by Mortdeus@gocos2d.org:

It would be nice to add 

`rwx(111[7]) rw(110[6]) rx(101[5]) r(100[4]) wx(011[3]) w(010[2]) x(001[1])`

as a godoc comment at

https://code.google.com/p/go/source/browse/src/pkg/os/types.go#56
@bradfitz
Copy link
Contributor

bradfitz commented Jan 9, 2014

Comment 1:

Why?  It's pretty cryptic and ugly.

@mortdeus
Copy link

mortdeus commented Jan 9, 2014

Comment 2:

well, some gophers were confused in #go-nuts last night. 
It would just be nice to have a more descriptive comment, instead of one that assumes
all gophers understand Unix conventions.

@bradfitz
Copy link
Contributor

bradfitz commented Jan 9, 2014

Comment 3:

And saying `rwx(111[7]) rw(110[6]) rx(101[5]) r(100[4]) wx(011[3]) w(010[2]) x(001[1])`
would teach them Unix?
It's possible we could add some comment, but it should be mostly English.

@davecheney
Copy link
Contributor

Comment 4:

@mortdeus if you would like to tackle this one that would be great.

Labels changed: added release-none, repo-main, suggested.

Status changed to HelpWanted.

@glacjay
Copy link

glacjay commented Feb 25, 2014

Comment 5:

maybe like this?
//                 read write exec
// 0777 (oct) = 0b   1    1    1    // user
//                   1    1    1    // group
//                   1    1    1    // other

@k4rtik
Copy link

k4rtik commented Oct 12, 2014

Comment 6:

Since `pkg` is gone, the correct URL referenced in OP for this issue is
https://code.google.com/p/go/source/browse/src/os/types.go#56
Also, I doubt this is really an issue. Even if someone doesn't know UNIX conventions for
permissions, how much time does it take to Google them up?

@gopherbot gopherbot added help wanted release-none Suggested Issues that may be good for new contributors looking for work to do. labels Oct 12, 2014
@rsc rsc added this to the Unplanned milestone Apr 10, 2015
@rsc
Copy link
Contributor

rsc commented Apr 14, 2015

Let's change "// permission bits" to "// Unix permission bits" and be done.

@rsc rsc changed the title add bitmask legend to os.FileMode's godoc documentation. os: document that FileMode permission bits are Unix bits Apr 14, 2015
@rsc rsc modified the milestones: Go1.5, Unplanned Apr 14, 2015
@rsc rsc added Documentation and removed help wanted Suggested Issues that may be good for new contributors looking for work to do. labels Apr 14, 2015
@bradfitz
Copy link
Contributor

@golang golang locked and limited conversation to collaborators Jun 25, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

7 participants