i think others have said most things i would say (as a programmer who started out with an astronomy phd), but two points that i don't think anyone else has mentioned:
1 - try to get a job in a "real" software company where you are "the maths guy" (or, easier, the existing maths guy's understudy), rather than in a company full of people like yourself (ie where most people are software engineers, not maths phds). in my experience that will help you learn how to be a professional engineer, use good practices, etc etc (although the variation between companies is still huge).
2 - you will be amazed at what most people think is "advanced maths". things that are completely basic for you (like, say, simple geometry or trigonometry) seem to be black arts for the majority of software engineers. this has a good and a bad side: the plus is that it makes what you have very valuable; the possible minus is that you could be asked to do quite boring work.
please don't take the second point to mean that there aren't some very smart, very mathematically competent software engineers out there, because there clearly are. but they are exceptions. value them when you find them.
what i am trying to say, i guess, is that your skills and those of a good software engineer are pretty much disjoint (and complementary, in the non-mathematical sense). so you both have much to gain/learn from the other. and if you can learn, then you become more valuable.