Skip to content

ls: ls -lF symlink target indicators#11554

Open
joknarf wants to merge 3 commits intouutils:mainfrom
joknarf:classify_target
Open

ls: ls -lF symlink target indicators#11554
joknarf wants to merge 3 commits intouutils:mainfrom
joknarf:classify_target

Conversation

@joknarf
Copy link
Copy Markdown

@joknarf joknarf commented Mar 30, 2026

Fixes #11542
gnu output incompatibility with --classify on symlink targets

before:

 • ls -lF mylink*
lrwxrwxrwx 1 user group 5 Nov 22 08:33 mylinktodir@ -> mydir
lrwxrwxrwx 1 user group 9 Nov 22 08:31 mylinktoexe@ -> myexec.sh
lrwxrwxrwx 1 user group 6 Nov 22 08:34 mylinktofile@ -> myfile
lrwxrwxrwx 1 user group 6 Nov 22 08:47 mylinktopipe@ -> mypipe
lrwxrwxrwx 1 user group 6 Mar 29 10:42 mylinktosock@ -> mysock

after (gnu identical output):

 • gnuls -lF mylink*
lrwxrwxrwx 1 user group 5 Nov 22 09:33 mylinktodir -> mydir/
lrwxrwxrwx 1 user group 9 Nov 22 09:31 mylinktoexe -> myexec.sh*
lrwxrwxrwx 1 user group 6 Nov 22 09:34 mylinktofile -> myfile
lrwxrwxrwx 1 user group 6 Nov 22 09:47 mylinktopipe -> mypipe|
lrwxrwxrwx 1 user group 6 Mar 29 10:42 mylinktosock -> mysock=

Copy link
Copy Markdown
Contributor

@Alonely0 Alonely0 left a comment

Choose a reason for hiding this comment

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

Looks fine, but there are a lot of removed comments (vibecode?) and unnecessary performance hits.

@github-actions
Copy link
Copy Markdown

GNU testsuite comparison:

Skip an intermittent issue tests/date/date-locale-hour (fails in this run but passes in the 'main' branch)
Skip an intermittent issue tests/tail/inotify-dir-recreate (fails in this run but passes in the 'main' branch)
Skip an intermittent issue tests/tty/tty-eof (fails in this run but passes in the 'main' branch)
Congrats! The gnu test tests/seq/seq-epipe is now passing!

@codspeed-hq
Copy link
Copy Markdown

codspeed-hq bot commented Mar 31, 2026

Merging this PR will not alter performance

✅ 304 untouched benchmarks
⏩ 46 skipped benchmarks1


Comparing joknarf:classify_target (d071234) with main (04b1585)

Open in CodSpeed

Footnotes

  1. 46 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@sylvestre
Copy link
Copy Markdown
Contributor

please fix the failing tasks

@Alonely0
Copy link
Copy Markdown
Contributor

@joknarf For the perf-related changes I requested, please try to git-apply this patch. It should also fix the formatting-related CI failures.
perf.patch

@Alonely0
Copy link
Copy Markdown
Contributor

Alonely0 commented Mar 31, 2026

I'm happy to sign off on this code provided CI likes it, but I'd still like to save those comments and (while I don't really care), I would appreciate if you could mark me as a co-author of the apply commit and give it a descriptive name, i.e:

fix(ls): take care of performance regressions

Co-authored-by: Guillem L. Jara <4lon3ly0@tutanota.com>

Since you're gonna have to do an interactive rebase, while you're at it please change your commits to follow our etiquette. Split 4ef7830 into a fix commit and a chore one that adds the test (squash the cSpell fix onto it), and use our naming conventions for them.

@joknarf joknarf changed the title ls -lF symlink target indicators ls: ls -lF symlink target indicators Mar 31, 2026
@joknarf
Copy link
Copy Markdown
Author

joknarf commented Mar 31, 2026

I'm happy to sign off on this code provided CI likes it, but I'd still like to save those comments and (while I don't really care), I would appreciate if you could mark me as a co-author of the apply commit and give it a descriptive name, i.e:

fix(ls): take care of performance regressions

Co-authored-by: Guillem L. Jara <4lon3ly0@tutanota.com>

Since you're gonna have to do an interactive rebase, while you're at it please change your commits to follow our etiquette. Split 4ef7830 into a fix commit and a chore one that adds the test (squash the cSpell fix onto it), and use our naming conventions for them.

Ok, I hope I did what you expect, Thank you

@joknarf
Copy link
Copy Markdown
Author

joknarf commented Mar 31, 2026

uutils/gnu ls output comparison:
image

Co-authored-by: Guillem L. Jara <4lon3ly0@tutanota.com>
@Alonely0
Copy link
Copy Markdown
Contributor

Signed off, looks good to me. Thanks @joknarf!

@sylvestre can we get a CI run?

@github-actions
Copy link
Copy Markdown

GNU testsuite comparison:

Skip an intermittent issue tests/tty/tty-eof (fails in this run but passes in the 'main' branch)
Skipping an intermittent issue tests/pr/bounded-memory (passes in this run but fails in the 'main' branch)
Note: The gnu test tests/printf/printf-surprise is now being skipped but was previously passing.
Note: The gnu test tests/tail/pipe-f is now being skipped but was previously passing.
Congrats! The gnu test tests/unexpand/bounded-memory is now passing!

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.

ls -lF (--classify) symlink target indicator missing

3 participants