4 ms·You could also do this: grep -n __main__ *.py|grep __name__ which turns up few false positives.by cabalamat 14y agoYou could also do this: grep -n __main__ *.py|grep __name__ which turns up few false positives.