You can do this: python -c "import py_compile; py_compile.compile( \"foo.py\", \"foo.pyc\" )" ...which will create foo.pyc *only*, and will not compile any other .py files imported by foo.py. Steven wrote: > Hi folks, > > Just curious, is there a python compiler? > Or something that creates bytecode, like java? > > Regards, > > Steven