summaryrefslogtreecommitdiff
path: root/logcheck/mklocalfiles
diff options
context:
space:
mode:
Diffstat (limited to 'logcheck/mklocalfiles')
-rwxr-xr-xlogcheck/mklocalfiles24
1 files changed, 24 insertions, 0 deletions
diff --git a/logcheck/mklocalfiles b/logcheck/mklocalfiles
new file mode 100755
index 0000000..06aa7fb
--- /dev/null
+++ b/logcheck/mklocalfiles
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+# Bad ass temp script to simply generate file "local" containing *all*
+# other files in it (until a proper cfengine script is written
+
+for dir in ignore.d.server ignore.d.workstation violations.ignore.d; do
+ echo regenerating $dir
+ rm -f $dir/local
+ # Include server lines in workstation as well
+ if [ "$dir" == "violations.ignore.d" ]; then
+ for file in ignore.d.server/*; do
+ if [ -f $file -a `basename $file` != "local" ]; then
+ echo "### $file" >> $dir/local
+ cat $file >> $dir/local
+ fi
+ done
+ fi
+ for file in $dir/*; do
+ if [ -f $file -a `basename $file` != "local" ]; then
+ echo "### $file" >> $dir/local
+ cat $file >> $dir/local
+ fi
+ done
+done