android-udev-rules
android-udev-rules copied to clipboard
`#!/usr/bin/env` should be avoided except when needed
https://github.com/M0Rf30/android-udev-rules/blob/6ceb4ccee158abddf7ab3b6f091c1264a648863d/install.sh#L1
Unnecessary implicit trust of the caller's environment:
- the
#!
line is untrustworthy; and - the
PATH=/usr/bin:/bin
line is missing.
There is a widespread myth that #!/usr/bin/env whatever is "more portable" than #!/path/to/whatever, but this particular project is only useful for Linux PC's where /bin/sh
is universally available (as it is on nearly every Unix system in existence).
Meanwhile this extraneous use of env
contributes to normalizing it in the minds of people who don't understand its problems and limitations.
See https://burnthewhich.github.io/shbangenv/shbangenv