mirror of
https://github.com/mrworf/plexupdate.git
synced 2025-07-16 02:02:58 -07:00
Merge pull request #80 from demonbane/fix-getopt
Fix to allow combined command-line options
This commit is contained in:
commit
357e716866
1 changed files with 6 additions and 1 deletions
|
@ -165,7 +165,12 @@ usage() {
|
|||
|
||||
# Parse commandline
|
||||
ALLARGS=( "$@" )
|
||||
set -- $(getopt acCdfhkopqruU: -- "$@")
|
||||
optstring="acCdfhkopqruU"
|
||||
getopt -T >/dev/null
|
||||
if [ $? -eq 4 ]; then
|
||||
optstring="-o $optstring"
|
||||
fi
|
||||
set -- $(getopt $optstring -- "$@")
|
||||
while true;
|
||||
do
|
||||
case "$1" in
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue