Skip to content

chown: warn when '.' is used as owner:group separator#11438

Open
eyupcanakman wants to merge 3 commits intouutils:mainfrom
eyupcanakman:fix/chown-dot-separator-warning-11352
Open

chown: warn when '.' is used as owner:group separator#11438
eyupcanakman wants to merge 3 commits intouutils:mainfrom
eyupcanakman:fix/chown-dot-separator-warning-11352

Conversation

@eyupcanakman
Copy link

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

When the spec contains '.' but no ':', emit a warning matching GNU
coreutils behavior: "warning: '.' should be ':': '<spec>'"

Closes uutils#11352
@eyupcanakman eyupcanakman force-pushed the fix/chown-dot-separator-warning-11352 branch from 20cc0f4 to 1b32857 Compare March 21, 2026 06:45
sylvestre and others added 2 commits March 21, 2026 12:18
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.
@codspeed-hq
Copy link

codspeed-hq bot commented Mar 22, 2026

Unable to generate the performance report

There 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.

let gid = parse_gid(group, spec)?;
return Ok((uid, gid));
}
show_warning!("'.' should be ':': {}", spec.quote());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please use the translate!() macro

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

chown: warning message

2 participants