mirror of
https://github.com/bensuperpc/dockcross.git
synced 2024-11-10 05:07:26 +01:00
dockcross: Remove duplicate option parsing
This commit is contained in:
parent
aab9632ab6
commit
a5d5307a97
@ -150,31 +150,6 @@ if [ -z $DOCKER_HOST ]; then
|
|||||||
USER_IDS="-e BUILDER_UID=$( id -u ) -e BUILDER_GID=$( id -g ) -e BUILDER_USER=$( id -un ) -e BUILDER_GROUP=$( id -gn )"
|
USER_IDS="-e BUILDER_UID=$( id -u ) -e BUILDER_GID=$( id -g ) -e BUILDER_USER=$( id -un ) -e BUILDER_GROUP=$( id -gn )"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
|
||||||
# Command-line processing
|
|
||||||
#
|
|
||||||
if [[ $# == 0 ]]; then
|
|
||||||
command:help
|
|
||||||
exit
|
|
||||||
fi
|
|
||||||
|
|
||||||
case $1 in
|
|
||||||
|
|
||||||
--)
|
|
||||||
# Everything after this is the command-line to be executed
|
|
||||||
shift
|
|
||||||
;;
|
|
||||||
|
|
||||||
*)
|
|
||||||
# If this is a builtin command, execute it, otherwise fall through
|
|
||||||
if has command $1; then
|
|
||||||
command:$1 "${@:2}" # array slice skipping first element
|
|
||||||
exit $?
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
|
|
||||||
esac
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
# Now, finally, run the command in a container
|
# Now, finally, run the command in a container
|
||||||
#
|
#
|
||||||
|
Loading…
Reference in New Issue
Block a user