Skip to content

Instantly share code, notes, and snippets.

@pazz
Created June 2, 2012 16:26
Show Gist options
  • Select an option

  • Save pazz/2859047 to your computer and use it in GitHub Desktop.

Select an option

Save pazz/2859047 to your computer and use it in GitHub Desktop.
vim spawnProcess
#usr/bin/python
from twisted.internet import reactor
from twisted.internet.protocol import ProcessProtocol
import StringIO
import os
cmdlist=['vim']
proc = reactor.spawnProcess(ProcessProtocol(), executable=cmdlist[0],
env=os.environ,
#usePTY=True,
childFDs = { 0: 0, 1: 1, 2: 2},
args=cmdlist)
reactor.run()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment