Skip to content

ln: print => for hard links with --verbose - #16016

Merged
cakebaker merged 2 commits into
uutils:mainfrom
sarankumar1325:fix/ln-verbose-hard-link-arrow
Oct 30, 2026
Merged

cakebaker merged 2 commits into
uutils:mainfrom
sarankumar1325:fix/ln-verbose-hard-link-arrow

Conversation

@sarankumar1325

Copy link
Copy Markdown
Contributor

Fixes #15985

GNU ln -v prints => for hard links and -> only for symbolic links. uutils printed -> for both.

$ touch a; ln -v a l
GNU:     'l' => 'a'
before:  'l' -> 'a'
after:   'l' => 'a'

ln -sv output is unchanged (->).

Tests: added test_hard_link_verbose; cargo test --features ln --no-default-features test_ln (68 passed), cargo fmt --check, cargo clippy -p uu_ln --all-targets. Expected output was checked by running GNU coreutils 9.7 ln -v, not by reading its source.

AI disclosure: I used an AI coding assistant for this change and reviewed it myself.

Copilot AI balanced review requested due to automatic review settings October 29, 2026 19:24

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing. Review the Copilot code review billing settings.

GNU ln -v uses '->' only for symbolic links and '=>' for hard links.

Fixes uutils#15985
@cakebaker
cakebaker force-pushed the fix/ln-verbose-hard-link-arrow branch from dd0f01f to a1db955 Compare October 30, 2026 09:15
Copilot AI balanced review requested due to automatic review settings October 30, 2026 09:15

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing. Review the Copilot code review billing settings.

Comment thread tests/by-util/test_ln.rs Resolved
Hard links are not permitted on the Android CI emulator, like the other
hard link tests in this file.
Copilot AI balanced review requested due to automatic review settings October 30, 2026 10:19

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing. Review the Copilot code review billing settings.

@cakebaker
cakebaker merged commit fee61ff into uutils:main Oct 30, 2026
98 checks passed
@cakebaker

Copy link
Copy Markdown
Contributor

Thanks!

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.

ln: --verbose should use => for hard links

3 participants