經安全檢測,此網站為安全網站,請放心前往原始網址!

How do I parse command line arguments in bash? - Stack Overflow

getopt()/getopts() is a good option. Stolen from here: The simple use of "getopt" is shown in this mini-script: #!/bin/bash echo "Before getopt" for i do echo $i done args=`getopt abc:d $*` set -- $args echo "After getopt" for i do echo "-->$i" done What

stackoverflow.com

網址安全性掃描由 google 提供