#!/bin/sh

ks="install/ks.cfg"

[ -e $ks ] || { echo "missing file $ks, create one based on $ks.default"; exit 1; }

sudo mount /mnt/floppy
cp -f $ks /mnt/floppy
perl -pi -e 's/prompt 1//; s/\s*kickstart=\S+//g; s/append/append kickstart=auto_inst.cfg.pl/' /mnt/floppy/syslinux.cfg
sudo umount /mnt/floppy