MicrosoftDocs / WSL

Source code behind the Windows Subsystem for Linux documentation.
https://docs.microsoft.com/windows/wsl
Other
1.9k stars 563 forks source link

umask docs #1767

Closed uecasm closed 1 year ago

uecasm commented 1 year ago

Documentation Issue

User file-creation mode mask (umask) sets permission for newly created files. The default is 022, only you can write data but anyone can read data.

The default shown in the table above this was 000. At least one of these must be incorrect.

The permission masks are put through a logical OR operation before being applied to files or directories.

A set bit in the umask results in a clear bit in the actual permissions (assuming it works how umask usually does, as the cited example seems to confirm); so it's more like a NAND, definitely not an OR.

Link to documentation page

https://learn.microsoft.com/en-us/windows/wsl/wsl-config#wsl-2-settings

Suggested Improvements

No response

uecasm commented 1 year ago

Also, since this uses the issue type templates it makes the "submit feedback for this page" button not work as intended...

mattwojo commented 1 year ago

Thanks for pointing this out @uecasm ! I fixed the umask default listed in the table in https://github.com/MicrosoftDocs/WSL/commit/8c167d6e72d8eb9f6c094dc4d8252f1184e99661

I'm not quite sure what you mean about the issue type template making "submit feedback for this page" not work... I just tried selecting that link on the bottom of the live page and it seemed to work fine. (?)

uecasm commented 1 year ago

I'm not quite sure what you mean about the issue type template making "submit feedback for this page" not work... I just tried selecting that link on the bottom of the live page and it seemed to work fine. (?)

When that button is clicked it goes to the https://github.com/MicrosoftDocs/WSL/issues/new/choose page. After clicking on the button there it opens up the corresponding mostly-blank template without the boilerplate that the learn site expects.

Compare for example with what happens when the same button is clicked at https://learn.microsoft.com/en-us/windows/dev-environment/