Skip to content

Instantly share code, notes, and snippets.

@maio
Forked from dizzi/gist:180271
Created September 3, 2009 12:34
Show Gist options
  • Save maio/180272 to your computer and use it in GitHub Desktop.
Save maio/180272 to your computer and use it in GitHub Desktop.
import ftplib
import sys
import os
ftpServer = 'xxx'
ftpUser = 'xx'
ftpPass = 'xx'
#ftpPath = 'FileFlowStatus/'
ftpPath = '/'
def reportThis(filename, filecontent):
f = file(filename,'rb')
f.close() # Close file and FTP
if __name__ == '__main__':
reportThis('/etc/passwd', 'lala')
print 'tadaa'
---------
$ python ftest.py
tadaa
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment