I'm on MacOS... :-/
$ find ./tmp -maxdepth 1 -type f -printf '%f\n'
find: -printf: unknown primary or operator $ find ./tmp -maxdepth 1 -type f -printf '%f\n'
find: -printf: unknown primary or operatorI also use MacOS and I have setup the gnu userland on my local so it matches the linux environment on our servers and containers.
It's not about convenience. It is about having a development environment that matches the target runtime environment.
You can run into nasty surprises when the default behavior of a tool in your dev environment is different than in your production environment.
I've been writing shell scripts professionally for over 20 years and I have always taken this approach and it has served me well.
Works for me on OSX.