7 echo "usage: termux-download <uri-to-download>"
8 echo " Download a resource using the system download manager."
9 echo " -d, --description Description for the download request notification"
10 echo " -t, --title Title for the download request notification"
14 O
=`busybox getopt -q -l description: -l title: -l help -- d:t:h "$@"`
15 if [ $?
!= 0 ] ; then show_usage
; exit 1 ; fi
19 -h|
--help) show_usage
; exit 0;;
20 -d|
--description
) PARAMS
="$PARAMS --es description '$2'"; shift 2;;
21 -t|
--title
) PARAMS
="$PARAMS --es title '$2'"; shift 2;;
23 *) echo Error
; exit 1;;
28 if [ $# != 1 ]; then show_usage
; exit 1; fi
30 eval @TERMUX_API@ Download
$PARAMS $1