|
4.2.2 Executable Python Scripts
On BSD'ish UNIX systems, Python scripts can be made directly
executable, like shell scripts, by putting the line
#! /usr/bin/env python
(assuming that the interpreter is on the user's ‘PATH’) at the
beginning of the script and giving the file an executable mode. The
‘#!’ must be the first two characters of the file. Note that
the hash, or pound, character, ‘#’, is used to start a
comment in Python.
|
|