Why would anyone need a library when we could just do this?
arg=default
while [ -n "${1}" ]
do
case "${1}" in
--arg)
shift
arg="${1}"
shift
;;
*)
print_help_page
shift
;;
esac
done
The above is terse, readable, and doesn't rely on any dependencies other than POSIX compatibility.Often the whole point of shell scripts is that they're dependency free; nothing is needed other than the shell. After all, why code rustup in sh if not for this reason?
People who make libraries like this for shell are, I think, missing the point of shell.