How to run another python script?
Sven
nomail at please.com
Mon Feb 14 13:38:54 EST 2011
On Mon, 14 Feb 2011 07:56:53 -0800, rantingrick wrote:
> On Feb 14, 9:51 am, Dan Lee <allbory.... at gmail.com> wrote:
>
>> AAA : generate zip file
>> BBB : delete old file.
>>
>> AAA is done.
>> Now I'm going to code BBB file. and I will fix AAA to call BBB to
>> delete dump file at the end.
>> Please let me know How can I call the BBB file from AAA file.
>
> Simple: Make a call using the underlying os from the aptly named "os"
> module (or other!). OR import BBB and execute the code.
I would however recommend using the subprocess module instead of the os
module.
http://docs.python.org/library/subprocess.html
--
./Sven
More information about the Python-list
mailing list