#!/bin/sh for arg in ${@}; do BASE=`basename $arg` FIND='\([ \t"]\)'${BASE//./\\.} REPLACE='\1'tx${BASE} find \( -name CVS -prune -a -type f \) -o -not \( -type d -o -name "*~" \) | \ xargs sed -i -e "s/$FIND/$REPLACE/"; done