Skip to content

Instantly share code, notes, and snippets.

@digi9ten
Created March 6, 2017 19:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save digi9ten/3afae754be57ab9cc8db68b417b37c58 to your computer and use it in GitHub Desktop.
Save digi9ten/3afae754be57ab9cc8db68b417b37c58 to your computer and use it in GitHub Desktop.
Small addition to your .bashrc that creates a alias that you can pass a url to, and it will retry it until it resolves
plsresolve() {
pls_resolve_rc=1
until [ $pls_resolve_rc -eq 0 ]; do curl "$1"; let pls_resolve_rc=$?; sleep 5; done
}
alias plsresolve=plsresolve
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment