blob: 66424e5f0d132f51e3130bad9cc3f289cb735235 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
#!/bin/sh
# APPLE LOCAL file maintenance
# Use in directory to prune, argument is corresponding mainline source dir.
# Output is list of commands to execute; save into file and review before
# executing.
diff -r --exclude CVS --exclude '*~' --exclude '*.#*' --brief $1 . \
| grep '^Only in \.' \
| sed -e 's,Only in \([^:]*\): \(.*\)$,\1/\2,' \
| sed -e 's,\./,,g' > /tmp/prunes
for fname in `cat /tmp/prunes`; do
if head -3 $fname |grep -q 'APPLE *LOCAL' || test -d $fname; then :
echo "# keeping $fname"
else
echo "rm $fname; cvs remove $fname"
fi
done
|