Skip to content

Instantly share code, notes, and snippets.

@martijnbastiaan
Created January 15, 2021 20:51
Show Gist options
  • Save martijnbastiaan/7a6bf2501cf2847e160e3ae90e9f3177 to your computer and use it in GitHub Desktop.
Save martijnbastiaan/7a6bf2501cf2847e160e3ae90e9f3177 to your computer and use it in GitHub Desktop.
#!/bin/bash
cd "$(dirname $0)"
stat_file="$(date --iso-8601=seconds).log"
baseline="http://dk.archive.ubuntu.com/xubuntu-cd/20.04/release/xubuntu-20.04.1-desktop-amd64.iso"
ghc="https://github.com/commercialhaskell/ghc/releases/download/ghc-8.10.3-release/ghc-8.10.3-x86_64-deb9-linux.tar.xz"
echo $(date --iso-8601=ns) > "${stat_file}"
rm -f out
timeout 3s wget -q "${baseline}" -O out
stat --printf="%s" out >> "${stat_file}"
echo "" >> "${stat_file}"
echo $(date --iso-8601=ns) >> "${stat_file}"
rm -f out
timeout 15s wget -q "${ghc}" -O out
stat --printf="%s" out >> "${stat_file}"
echo "" >> "${stat_file}"
echo $(date --iso-8601=ns) >> "${stat_file}"
rm -f out
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment