So, I've been able to change a good deal of the post processor to suit my shops preferences. A couple things I'm stuck on:

It outputs a G17 in the first line, and a G20 in the second line. Since the CNC we have defaults to that anyway, can I remove these from the post sequence? If so, how?

And at the end of the program, my partner wants to see:

M5
G91G30Z0.M9
G28Y0.
M30

It's currently giving me a G30 Z0 on the first line, but the next line is G30 Y0....

Also, is there a way to have N numbers ONLY on the toolchange? My partner has worked a certain way for a LONG time. He is used to seeing:
N10 T1 M6
N20 T2 M6
N30 T3 M6
so on and so forth......

Thanks,

Seth