The following aliases return all the same number of results, on my Cygwin (on Windows):
file-history1 = log --
file-history2 = log
file-history5 = "!f() { git show -s $(git rev-list --date-order HEAD -- $1); }; f"
file-history6 = !sh -c 'git show -s $(git rev-list --date-order HEAD -- $0)'
But what would be the best / worse ones in there?
I'd like to write portable aliases, that will work similarly on Windows (Cygwin or Git Bash) / Linux / MacOS...
I do have a favor for #5 and #6 as they show that they expect an argument. But that would be disregarded if they don't execute properly on other platforms...
bash
and nowadays useszsh
by default. I honestly think the esaiest thing would be to test this in containers of the types of OSes, etc. that you hope to support. \$\endgroup\$