summaryrefslogtreecommitdiff
path: root/logcheck/mklocalfiles
blob: 06aa7fbec999382c6a400e359865735f4fb0c85d (plain)
  1. #!/bin/sh
  2. # Bad ass temp script to simply generate file "local" containing *all*
  3. # other files in it (until a proper cfengine script is written
  4. for dir in ignore.d.server ignore.d.workstation violations.ignore.d; do
  5. echo regenerating $dir
  6. rm -f $dir/local
  7. # Include server lines in workstation as well
  8. if [ "$dir" == "violations.ignore.d" ]; then
  9. for file in ignore.d.server/*; do
  10. if [ -f $file -a `basename $file` != "local" ]; then
  11. echo "### $file" >> $dir/local
  12. cat $file >> $dir/local
  13. fi
  14. done
  15. fi
  16. for file in $dir/*; do
  17. if [ -f $file -a `basename $file` != "local" ]; then
  18. echo "### $file" >> $dir/local
  19. cat $file >> $dir/local
  20. fi
  21. done
  22. done