This snippet of code: import os f = os.popen('gpg --sign gpgtest.py','w') f.write("Test\n") Doesn't work for me, and I'm a bit baffled (and annoyed) because I can't find the problem. Thanks in advance. -Morten