ITEMS=$2
PRIORITY=$3

if [[ $ITEMS =~ ^([0-9]+)-([0-9]+)$ ]]; then
	START=${BASH_REMATCH[1]}
	END=${BASH_REMATCH[2]}
	for i in $(seq $START $END); do
		todo.sh command pri $i $PRIORITY || break
	done
else
	todo.sh command pri $ITEMS $PRIORITY
fi
