#!/bin/rc

if(~ $#* 0){
	echo usage: g [grep opts] pattern
	exit 'usage'
}

du -a |
	grep '\.h$|\.c$|\.C$|\.c++$|\.C++$|\.cpp$|\.hpp$|\.H$|\.h++$\.s++$|\.S++$' |
	while(match=`{read})
		grep -n $* $match(2) /dev/null


