Skip to content

Instantly share code, notes, and snippets.

@adamryman
Created December 24, 2016 03:22
Show Gist options
  • Save adamryman/e53d547698d6a38c1937c6e099d019df to your computer and use it in GitHub Desktop.
Save adamryman/e53d547698d6a38c1937c6e099d019df to your computer and use it in GitHub Desktop.
Build a go project and count how many seconds have passed then print `time` that it took.
a=1; done=0; while [[ ! -e "./__done__" ]]; do sleep 1; echo $a; a=$(($a+1)); done & time go build ./... && touch __done__ && sleep .99 && rm __done__
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment