Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python
- # this is from The Python
- # Standard Library by example
- # ISBN13: 9780321767349
- import subprocess
- print 'read:'
- proc = subprocess.Popen(['echo', '"to stdout"'],
- stdout=subprocess.PIPE,
- )
- stdout_value = proc.communicate()[0]
- print '\tstdout:', repr(stdout_value)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement