Shell commands from within a script

Neil Fryer neil at
Wed Nov 14 15:23:06 CET 2001

Thank you

Neil Fryer
neil at

On Wednesday 14 November 2001 10:02 pm, Stefan Antoni wrote:
> On Wed, Nov 14, 2001 at 03:42:12PM +0200, Neil Fryer wrote:
> > I'm really new to python so if you could please let me know how to
> > execute a command like say, ftp, from within a script it really would be
> > appreciated. As I'm only about half way through my first Python tutorial.
> import os
> os.system('ftp')
> ... this executes ftp from within your script.
> have a closer look into the os module, there are many other interesting
> ways to use commands, pipes, fork()'s and so on.

More information about the Python-list mailing list