Differences between revisions 1 and 2
Revision 1 as of 2008-04-14 10:59:03
Size: 206
Editor: anonymous
Comment:
Revision 2 as of 2008-04-15 12:23:13
Size: 403
Editor: anonymous
Comment:
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
#acl AdminGroup:read,write EditorGroup:read All:read #acl AdminGroup:read,write
Line 13: Line 13:


{{{#!python
#!/usr/bin/env python
import os,glob

filelist=glob.glob('*.pdf')
for f in filelist:
    psfilename=f.split('.')[0]+'.ps'
    cmd='pdftops '+f+' '+psfilename
    print cmd
    os.system(cmd)
}}}

I/O

Interaction with the operating system

Module sys

Module os

   1 #!/usr/bin/env python
   2 import os,glob
   3 
   4 filelist=glob.glob('*.pdf')
   5 for f in filelist:
   6     psfilename=f.split('.')[0]+'.ps'
   7     cmd='pdftops '+f+' '+psfilename
   8     print cmd
   9     os.system(cmd)

LehreWiki: SiaProgrammingPythonSystem (last edited 2008-04-21 12:09:59 by anonymous)