1
0
Fork 0
mirror of https://github.com/mfornos/awesome-microservices.git synced 2024-11-20 11:16:15 -05:00
microservices/test/check.sh

17 lines
312 B
Bash
Raw Normal View History

2015-05-03 15:17:36 -04:00
#!/usr/bin/env bash
#
2015-05-03 15:21:36 -04:00
# README Checks
# =============
#
# - Prints dead links
2015-05-03 15:17:36 -04:00
#
DIR=$(dirname $0)
cat $DIR/../README.md | grep -o -E 'https?://[%\+-_./[:digit:][:alpha:]]+' | \
xargs -n1 -P 10 curl -o /dev/null --silent --head --write-out '%{url_effective} %{http_code}\n' | \
awk '$2 >= 400'
exit 0