The vast majority of Homebrew packages are not available as .dmg or .pkg ; installing that way also is a huge PITA when dealing with a myriad of small developer tools that require dependencies, whereas brew manages all of that for you, including upgrades.
The pkg manager does track all the files it installs, so it's a trivial script to go "uninstall" them. Anyway, good reason to stick with Homebrew.
I've thought about starting a project (possibly with some support from my company, which focuses on Linux packaging) to provide a) a tool to download and install .pkg files, and b) a toolchain for more easily building .pkg files for the things that aren't available.
I guess you mean BSD and GNU extensions to POSIX.
POSIX IEEE Std 1003.1, 2013 Edition defines sh as the shell.
There is no git in POSIX IEEE Std 1003.1, 2013 Edition.
The people that are likely to use advanced features would also hopefully be aware of Bash's fragility/compatibility issues between minor versions, and thus wouldn't rely on it for anything like shell scripts.
So we're left with people who want to use advanced features and are doing so purely on machines they control.. So what stops them from either compiling their own bash, or using one of the third party package managers to install it?
But I have less of an interest in that than in discouraging jerkish pedantry.
I still hate homebrew, of course, because it doesn't handle dependencies well at all, but I'm not 100% ready to switch to nix. Maybe that can be my project for the week, actually.
More power.
However, I'm not a fan of the soft recommendation for Homebrew. I understand Homebrew places everything in `/usr/local` but software installs on Mac should generally conform to dragging and dropping bundles inside `/Applications`.
In my experience, requirements to install packages using Homebrew could be circumvented by searching for .dmg or .pkg equivalents. The benefit is that software so installed is much easier for intermediate users to track and maintain.