Skip to content

Instantly share code, notes, and snippets.

View doug-rosser's full-sized avatar

Doug Rosser doug-rosser

  • Portland, OR
View GitHub Profile
[root@hoyt-mom ~]# cat get_compile_times.sh
#!/usr/bin/env bash
DATE="$1"
shift
for x in "$@"
do
egrep "Compiled catalog|Compiled static catalog" /var/log/puppetlabs/puppetserver/puppetserver.log | grep "^$DATE $x:" | awk '{print $16}' | python -c "import sys; print sum(float(l) for l in sys.stdin)"
done
drosser@drosser:~/MacBook/temp$ cat pe_acceptance_tests_drosser/get_compiles.sh
#!/usr/bin/env bash
# NOTE: you may need to change "Compiled catalog" to "Compiled static catalog"
# Usage example: ./get_compiles 2017-09-27 05 06 07 08
DATE="$1"
shift
for x in "$@"