| 123456789101112131415161718192021222324252627282930313233343536 | #!/usr/bin/env bashasync="true"interval="0.1"if [ "$1" = "-s" ]; then  async=""  shiftelif [ "$1" = "-i" ]; then  interval="$2"  shift 2fihost="$1"shiftif [ -z "$host" ] || [ ! -z "$@" ]; then  echo "Usage: $0 [-s | -i <interval>] <host uri>"  exit 1fi# insert newline after uuidsids="$(echo | cat 'uuids.txt' - 'usernames.txt')"# `brew install coreutils` on OS Xids="$(shuf <<< "$ids" 2>/dev/null || gshuf <<< "$ids")"bulk() {  trap return INT  echo "$ids" | while read id; do    if [ -z "$async" ]; then      curl -sSL -o /dev/null -w "%{url_effective} %{http_code} %{time_total}s\\n" -- "$host/avatars/$id?helm"    else      curl -sSL -o /dev/null -w "%{url_effective} %{http_code} %{time_total}s\\n" -- "$host/avatars/$id?helm" &      sleep "$interval"    fi  done}time bulk
 |