install_ci.sh 446 B

1234567891011121314151617181920
  1. #!/bin/bash
  2. set -ex
  3. # Find all of our external imports and update them.
  4. updated=false
  5. for attempt in 1 2 3; do
  6. if ( go list -f '{{join .Imports "\n"}}' ./... && go list -f '{{join .TestImports "\n"}}' ./...; ) \
  7. | sort -u \
  8. | fgrep -v github.com/tsuna/gohbase \
  9. | xargs go get -d -f -u -v; then
  10. updated=true
  11. break
  12. fi
  13. sleep $((attempt*attempt))
  14. done
  15. if ! $updated; then
  16. echo failed to update dependencies
  17. exit 1
  18. fi