I need to pass more than one value to an argument (the number of values I'm passing is different each time), but how can I do it? Here's my code:
usage() { echo "Usage: $0 [-i <string>]" 1>&2; exit 1; }
while getopts ":i:" o; do
case "${o}" in
i)
i=${OPTARG}
;;
*)
usage
;;
esac
done
scripts.sh PARAM1=value1,value2,value3? or #2scripts.sh PARAM1=value1 PARAM1=value2