generic2m.py 475 B

1234567891011121314151617181920
  1. import socket
  2. import os
  3. import sys
  4. home = os.path.expanduser('~')
  5. importpath = os.path.join(home, 'Documents', 'lab', 'm2b')
  6. #sys.path.append(importpath)
  7. host = '127.0.0.1'
  8. port = 6006
  9. UUID = 'F2FCB409-9E40-CC3B-ED2B-A8BD80D9D1B3'
  10. message = 'import sys;sys.path.append("/Users/jwoelper/Documents/lab/m2b");import m2b;m2b.update("' + UUID + '")'
  11. maya = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
  12. maya.connect( (host,port) )
  13. print maya.send(message)
  14. maya.close()