#!/bin/sh
# http://www.berklix.com/~jhs/bin/.sh/nospamweb
# bourne shell script by Julian H. Stacey

# ~/bin/.sh/nospamweb by jhs, calls ~/bin/.sh/nospam
# To make all my web pages less useful for spammers who gather addresses
# with web crawlers.

cd /tmp		|| exit
cd $HOME/tmp	|| exit
cd $HOME/public_html
cp `which nospam`	$HOME/tmp/nospam
# Save this script so it does not mutilate itself.
# JJLATER now trap signals.
# find . -type f \( \! -name \*.gif -and \! -name \*.jpg -and \! -name \*.pcl \
	-and \! -name \*.ps \) \
#	-exec $HOME/tmp/nospam {} \;
find . -type f \( -name \*.html -o -name \*.txt -o -name \*.asc -o -name \*.1 \
	-name \*.c -o -name \*.h -o -name Makefile \) \
	-exec $HOME/tmp/nospam {} \;
# find bin dots -type f -exec $HOME/tmp/nospam {} \;
find src/bsd/fixes -type f -exec $HOME/tmp/nospam {} \;
# Restore it after it has mutilated itself
# JJLATER now drop to here on a caught signal.
cp $HOME/tmp/nospam	`which nospam`	

# postscript files will have to have the AT sign zapped in the source rodf file,
# not here, too trick manipulating a postscript file
