Preventing burnout for programmers

Programming has been a hobby for me since I was 12. I'm 40+ now. The first time I got burned out the mere thought of programming made me sick, I felt a strong need to puke. The burnout was due to many factors, work was maybe 40% of that.

After that, I've struggled with various health issues. First it was lack of B12. I couldn't sleep, and at work I couldn't stay awake, and stomach problems. B12 pills and sertraline made me somewhat ok again. I managed to work for a few years. Then I started to get lots of headaches, neck pain and so on. Lots of different SSRI and painkillers did nothing. I am now treated for low testosterone. So far it hasn't changed much, still some pain, still tired, can't focus, bad memory(imagine your wife saying to you "but we talked about this one hour ago and you said it was a good idea and that we should do it" but you don't recall that conversation at all).

I guess what I'm trying to say is that your body and mind are very vulnerable when you are close(or have gone past) the edge of what you can manage. You get all sorts of weird interactions and depletions of things in the body.

I don't know exactly what causes it, but it's very easy to get too little sun light(vitamin d), too little exercise(a few walks per week would be sufficient), eat bad or only eat food that tingles the reward system(fast food), avoid social contact because you are tired and feel insecure.

I can get into "the zone" but it's hard at work due to too many interruptions and direction changes.

Regarding deadlines and extra hours, I don't do them. I used to, but after sacrificing holidays to finish something, and then one month later it was decided that we'll spend 2 years rewriting the entire system in .Net I don't really care about deadlines. I'm honest about this, and say, keep the backlog prioritized, let us know in good advance about important dates and we'll make it by being more focused.

/r/programming Thread Link - medium.com