Gary Wu | ee95ea5 | 2018-01-25 16:06:29 -0800 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | set -xe -o pipefail |
| 3 | |
| 4 | echo Job triggered by $SRC_BUILD_URL |
| 5 | echo Retriving logs from $LOG_DIR_URL |
| 6 | |
| 7 | rm -rf archives |
Gary Wu | 7087ff6 | 2018-05-03 16:03:24 -0700 | [diff] [blame] | 8 | mkdir -p archives |
| 9 | curl -f "$SRC_BUILD_URL/timestamps/?time=HH:mm:ssZ&appendLog" > archives/console-source-timestamp.log |
Gary Wu | ee95ea5 | 2018-01-25 16:06:29 -0800 | [diff] [blame] | 10 | wget -r -nv -nd --no-parent -l 1 --reject="index.html*" -P archives "$LOG_DIR_URL" |
Gary Wu | 7087ff6 | 2018-05-03 16:03:24 -0700 | [diff] [blame] | 11 | if [ -s archives/console-source-timestamp.log ]; then |
| 12 | cat archives/console-source-timestamp.log |
Gary Wu | ae3241d | 2018-05-03 11:15:00 -0700 | [diff] [blame] | 13 | else |
| 14 | cat archives/console.log |
| 15 | fi |