I've made my own Arduino derivative for a project. I'd like to build a few of these that both have the Arduino bootloader and a custom sketch uploaded, so I started putting together a jig with a ZIF socket and 6-pin ISP header to program the ATMega328p chips quickly.
The only problem is, if I recall, the Arduino environment lets you burn the bootloader via ISP, but if you program via ISP, you wipe the bootloader (normally a good thing because you get extra memory).
But I want to ship with both an Arduino bootloader and a custom sketch preloaded. Is there a way to do that all in one step via the ISP port?