Open
Conversation
stat: Fix timestamp leading '+' by casting year to u32. Add Linux-specific StatFs struct layout (macOS layout produced garbage on Linux). Add /proc/self/mountinfo parsing for mount point and device name on Linux. chown: Implement GNU "user:" login group resolution. When a colon follows the user name with no group, set group to the user's primary GID from passwd. cp: Remove -N from symlink follow_none logic. BSD -N suppresses file flags with -p; it should not affect symlink dereferencing. Fix cp -f read-only directory test setup to also make the destination file read-only (matches GNU behavior).
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.
Summary
+sign (Zig 0.15 formats signed ints with+when zero-padded; cast year tou32). Add Linux-specificStatFsstruct layout (the macOS struct layout was producing garbage block sizes on Linux). Add/proc/self/mountinfoparsing for mount point and device on Linux.user:login group resolution per spec: "if a colon follows the user name but no group name is given, the user's login group is used."-Nflag -- it suppresses BSD file flags with-p, not symlink dereferencing. Fix-fread-only directory test setup to also make destination file read-only (matches GNUcpbehavior where writable files in read-only dirs can be overwritten).Test plan
just it-util stat-- 30/30 passedjust it-util chown-- 87/87 passedjust it-util cp-- 137/137 passedzig build test --summary all-- all unit tests pass