Structual bashrc

This commit is contained in:
2014-08-04 17:40:25 +08:00
parent 56a34a1f12
commit 00e123d9fa
8 changed files with 180 additions and 3 deletions

View File

@@ -0,0 +1,13 @@
#!/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
}