utils/bash/bashrc/sources/60_diagnostics
2014-08-04 17:40:25 +08:00

14 lines
341 B
Bash
Executable File

#!/bin/bash
function catlog () {
if [[ -z "$1" ]]; then
__func_head "FILE"
echo " Will exclude:"
cat ~/.settings/checklog_exclude | awk '{ print " "$1 }'
echo
else
EXCLUDE=$(awk '{ printf("(%s)|", $1) }' ~/.settings/checklog_exclude | sed 's/|$//')
egrep -v $EXCLUDE $1
fi
}