This post is older than a year. Consider some information might not be accurate anymore.
I have to write some lightweight python programmes for rhel. I was wandering how to compile all python source files (*.py) in a my source directory.
On the console just call the module py_compile
and put the asterisk for the list of files to compile
python -m py_compile *.py