def makeKickstartFloppy():
 kickstart = 'ks.cfg'
 with open(kickstart, 'w') as f:
  f.write(KickstartText)
 preseed = 'ks.preseed'
 with open(preseed, 'w') as f:
  f.write(PreseedText)
 floppy = 'ksfloppy.img'
 run(('qemu-img create %s 1440k' % floppy))
 run(('mkfs -t msdos ' + floppy))
 run(('mcopy -i %s %s ::/' % (floppy, kickstart)))
 run(('mcopy -i %s %s ::/' % (floppy, preseed)))
 return (floppy, kickstart, preseed)

def makeKickstartFloppy ( ) : kickstart = 'ks.cfg' with open ( kickstart , 'w' ) as f : f . write ( KickstartText ) preseed = 'ks.preseed' with open ( preseed , 'w' ) as f : f . write ( PreseedText ) floppy = 'ksfloppy.img' run ( ( 'qemu-img create %s 1440k' % floppy ) ) run ( ( 'mkfs -t msdos ' + floppy ) ) run ( ( 'mcopy -i %s %s ::/' % ( floppy , kickstart ) ) ) run ( ( 'mcopy -i %s %s ::/' % ( floppy , preseed ) ) ) return ( floppy , kickstart , preseed )
create and return kickstart floppy .