@@ -0,0 +1,745 @@
+#!/usr/bin/env python%0A'''This connects to an ftp site; does a few ftp stuff; and then gives the user interactive control over the session.%0A'''%0Aimport pexpect%0Aimport sys%0A%0Achild = pexpect.spawn('/usr/bin/ftp upload.sourceforge.net')%0Achild.expect('Name .*: ')%0Achild.sendline('anonymous')%0Achild.expect('Password:')%0Achild.sendline('noah@noah.org')%0Achild.expect('ftp%3E ')%0Achild.sendline('cd /incoming')%0Achild.expect('ftp%3E ')%0Achild.sendline('bin')%0Achild.expect('ftp%3E ')%0Achild.sendline('put pexpect-current.tgz')%0Achild.expect('ftp%3E ')%0Achild.sendline('put pexpect-doc.tgz')%0Achild.expect('ftp%3E ')%0Achild.sendline('put pexpect-examples.tgz')%0Achild.expect('ftp%3E ')%0Achild.sendline('ls pexpect*')%0Achild.expect('ftp%3E ')%0Aprint child.before%0Achild.sendline('bye')%0A%0A

Eat my own food.