chown: warn when '.' is used as owner:group separator#11438
Open
eyupcanakman wants to merge 3 commits intouutils:mainfrom
Open
chown: warn when '.' is used as owner:group separator#11438eyupcanakman wants to merge 3 commits intouutils:mainfrom
eyupcanakman wants to merge 3 commits intouutils:mainfrom
Conversation
When the spec contains '.' but no ':', emit a warning matching GNU coreutils behavior: "warning: '.' should be ':': '<spec>'" Closes uutils#11352
20cc0f4 to
1b32857
Compare
On BSDs, new files inherit the group from the parent directory (e.g. /tmp -> wheel) rather than the user's primary group. Accept both "retained as" and "changed ownership" in the verbose output since either confirms the dot separator was parsed correctly.
Unable to generate the performance reportThere was an internal error while processing the run's data. We're working on fixing the issue. Feel free to contact us on Discord or at support@codspeed.io if the issue persists. |
sylvestre
reviewed
Mar 22, 2026
| let gid = parse_gid(group, spec)?; | ||
| return Ok((uid, gid)); | ||
| } | ||
| show_warning!("'.' should be ':': {}", spec.quote()); |
Contributor
There was a problem hiding this comment.
please use the translate!() macro
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
GNU chown emits a diagnostic when '.' is used instead of ':' as the owner:group separator. The uutils version silently accepted it.
Now emits
warning: '.' should be ':': '<spec>'matching GNU behavior. Both owner and group are still applied correctly when the dot separator is used.Closes #11352