-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
ls: some improvements after #9431 #10149
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
GNU testsuite comparison: |
|
GNU testsuite comparison: |
src/uu/ls/src/colors.rs
Outdated
| #[cfg(unix)] | ||
| mod unix_mode_bits { | ||
| // Unix file mode bits | ||
| pub const MODE_SETUID: u32 = 0o4000; | ||
| pub const MODE_SETGID: u32 = 0o2000; | ||
| pub const MODE_EXECUTABLE: u32 = 0o0111; | ||
| pub const MODE_STICKY_OTHER_WRITABLE: u32 = 0o1002; | ||
| pub const MODE_OTHER_WRITABLE: u32 = 0o0002; | ||
| pub const MODE_STICKY: u32 = 0o1000; | ||
| } | ||
|
|
||
| #[cfg(unix)] | ||
| use unix_mode_bits::*; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here it might be an option to rename unix_mode_bits to just mode. It would allow you to get rid of the MODE prefix of the constants.
src/uu/ls/src/colors.rs
Outdated
| return Some(Indicator::RegularFile); | ||
| fn indicator_for_symlink( | ||
| &self, | ||
| _path: &PathData, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would remove _path, it's never used.
3ba3dd8 to
f07f5b9
Compare
|
GNU testsuite comparison: |
follow up #9431