Closed pszafer closed 4 years ago
Code looks good. Have you confirmed this works correctly on both Alpine and non-Alpine distros?
Checked on Arch Linux (so GNU stat) and Alpine Linux, both works on fresh installs... but if somebody will install this package https://pkgs.alpinelinux.org/package/v3.11/main/x86/coreutils then it will have gnu stat as well.
So there are 3 options
stat --help
, fetch it and check if there is:
BusyBox
-> new way of checkingJust so I'm clear: if people running Alpine Linux install the coreutils
package, then the stat
command will work on Alpine Linux without merging this PR?
yes. coreutils package contains gnu stat.
OK, then I think I'd prefer to just mention that requirement for Alpine Linux in the README instead of adding custom logic to the script.
Would you like to adjust the PR to instead add that doc to the README, or should I instead close the PR and add it myself?
I can change this PR tomorrow.
OK, great.
Maybe change the Tested to work on Linux/FreeBSD/OS X
to a bullet list -- I think that'll make it easier to add individual caveats for each OS in the future.
As in the title. Let's check if disto is Alpine Linux, so then we know that we're using busybox stat.