1#!/bin/bash 2 3# Rules directory (fileecho) 4RULES_DIR=/ext/ftn/fileareas/xofcerules 5 6# Dir with symlinks, must be defined as RulesDir in fidoconfig 7SYMLINK_DIR=/ext/ftn/misc/rules 8 9for rulefile in `ls $RULES_DIR/*.rul` ; do 10 rulesname=`grep 'Area :' $rulefile | tr -d [:space:] | cut -b 6- -` 11 rulesname=`echo $rulesname | gawk '{ print tolower($1) }'` 12 if [ ! -f $SYMLINK_DIR/$rulesname.rul ]; then 13 ln -s $rulefile $SYMLINK_DIR/$rulesname.rul 14 fi 15done 16