Added more documentation.
[OpenFOAM-1.5.x.git] / bin / rmdepall
blob84e65267410fa146989f744ada55c549876d2f49
1 #!/bin/sh
3 if [ $# -eq 0 ]
4 then
5 find . \( -name '*.dep' \) -print | xargs -t rm
6 elif [ $# -eq 1 ]
7 then
8 echo "Removing all dep files containing $1..."
9 find . -name '*.dep' -exec grep "$1" '{}' \; -exec rm '{}' \;
10 else
11 echo "Usage: ${0##/} to remove all .dep files"
12 echo " ${0##/} <file> to remove all .dep files referring to <file>"
13 exit 1