Well, first let's not associate your 'depression' with 'work'. Sure, work can suck. Losing jobs and running through a cycle of them in a short amount of time can be sucky, too.

I've been in sales. Looking for work is the hardest sale. If someone doesn't want your vacuum cleaner, it's the product. If they think your life insurance rates are too high, it's the product. When job hunting, YOU are the product. And 95% of the time, you have no idea why you were rejected/ignored, and the few employers that tell you why either lie (unhelpful) or tell you things about yourself that you can't easily change (you're overqualified, your job history is not stable enough, you want too much money, etc.)

So, with a lot of job searches in a short amount of time, that can add to it. And I've had a LOT of jobs in my 20+ years of employment (some lasting only three days), so I know how you feel. Like you keep getting on the same roller coaster and you didn't even want to buy a ticket.

But let's be serious about one thing. This type of work - knowledge work - is detrimental to our overall health. You can do everything else right - fitness, eating healthy, pleasant and solid relationships, be a great parent (or son/daughter), have a great spiritual life - and sitting in front of a machine, no matter how much you love programming, and you and me are slowly killing ourselves.

Some people cope better at it. I happen to think grossly overweight people who consume large amounts of caffeine and sugary drinks and eat red meat are going to drop dead one day without warning, but in the meantime, they seem to excel at coping with such a sedentary lifestyle better.

For me, and maybe you can relate, it is incredibly unpleasant, increasingly, to be associated/tied to a machine. I love people. The "app-driven, put our life on social media, program your way to ninja/ping-pong coding guru" dream that we have been sold is hollow and pointless. And we all know it.

Balance is key. Finding it is hard.

My quick suggestions for you. Let me put it this way. Don't even think too much about these. I know, I know, you're an engineer/programmer mentality and over-analysis is all you know. But for once, since you're clearly struggling here, put some trust in someone else. I have a ton of children (way more than I can count) and have found this is hugely important stuff to maintaining balance. I hope it helps you, my friend.

1. NO devices after dark. Yeah, I don't care how crazy that sounds. You can watch TV, but no in-your-face devices, including Kindles, after dark. Shut them down. If true emergency happens, use F.lux for your laptop to keep blue-light at a minimum if you absolutely must email mom back at 10pm. Else, keep them off.

2. Walk 3 miles every day. Every single day. Throw your car keys in a drawer and walk three miles. Two miles is your 'off/easy' day. Three minimum. No device looking while you walk, except to play music or listen to a non-tech podcast. Learn a language, listen to American Life (stories about other people's problems), something. But no checking email. Go into airplane mode while walking. Ideally, have a PURPOSE or place to go to while walking. Could be work (once you get a job) if it is the right distance. Could be the grocery store. Could be a friend's house. Just try not to walk to/fro - it gets boring quick. Treadmills don't count. It MUST be outside.

3. Talk to one stranger every few days. About anything but tech. Don't compare phones. Ask him/her about their coffee, their outfit, the book they are reading, the car they drive, their child's funny hat... something. Get outside yourself, and reach out to others. Don't try and "collect data" on these people, even if they are cool and friendly. Don't worry about getting their email, phone, or Twitter handle. Just talk and let them stream past your life. My rule is this: if I stumble upon them a second time by pure chance (i.e. no stalking the barista girls), then maybe I try to make more of a connection, assuming the interest is mutual.

4. Get up early. Google it. I don't have time to sell it. But do it. 5AM is NOT early. But that will be a good start.

5. Do not work out in a gym. I don't care how much you like it. Find a ropes or fitness course and replace it with that, if you were working out. If not working out, and are in okay shape, then leave it alone. Your walking alone will be a huge help.

6. Don't compare yourself to others. I'm sure you have amazing talents and skills. So does everyone else. Nobody cares. Quit trying to be better and reading tech books, or how-to books (if you do). Read for pleasure at least every other book. Unsubscribe to tech magazines if you get them.

7. Along those lines, unsubscribe to as many things as you can. Interuptus Annoyance. And that means (gasp) deactivating Twitter. Promise yourself you won't reactivate (if ever) when you are Truly Happy. Might be hard at first. Same with social media. Cut out bloat. More than 50+ friends are bloat. 100+ is insanity. Log into FB and other similar sites only twice a week. Ideally, never, but I'm not going to push you to be a scrooge.

8. If you have a loved in your life, (didn't sound like it), give them a kiss and hug everyday and tell them you love them. Maybe for now that's your parents.

I hope that helps, friend. And don't let Silicon Valley be your standard. YOU be your standards. No one laments not affording it there. It's a crazy place to live. Live where you want. Follow YOUR dreams.