Here is my current code and I also prefer to show matched file name as well (if the content of the file matched grep), any solutions are appreciated.
for file in *.py;
do grep -n --color 'main' $file;
done
BTW, I am using Linux/OS X.
thanks in advance, Lin