Some windows are worth repairing, especially those with multi panes and unusual shapes.
Leaded glass can become quite expensive to repair but again, if it is unique it is probably worth the bill.
When prepping old windows, always wear a mask and gloves. You can pretty much guarantee there will be lead in the old paint. It is also best to work outside especially when sanding.
There are four steps to preparing your window.
The first step is to remove any old hardware, broken glass and chipping putty. Careful when removing the old screws as they can strip easily. And be especially careful when removing old glass.
The second step is to decide whether or not you will be stripping all the old paint off, if any.
I generally leave the paint on and just sand out any loose bits. I like it to look old and chippy.
The third step is to fill any large holes with Bondo. Bondo works perfect and you can sand it to any shape. This is especially good for those areas that are missing some of the wood on the outside.
The fourth step would be to replace the glass and any necessary putty.
The last step is to paint or stain your window. Just a side note that when it comes time to fitting the window, you may have to do some touching up.