Bad habits are like kudzu or English ivy: easy to start and extremely difficult to get rid of. When having a flare up of the depression or anxiety, bad habits multiply for me like fruit flies on rotten fruit.
One of my current bad habits is that of taking a nap to circumvent part of the day. Sometimes I just see hours stretched out before me and nothing I feel I want to do with them and they look difficult to endure, so I take one of my hours-long naps and wallah! Afternoon is gone. (And I've allowed my emotions ("I don't feel like it") to manage me rather than the other way around.)
Also gone are the opportunities to work on my novel, to clean something, to draw, to read, to look for a good basic starter yoga routine, to exercise, and to do any number of other useful things, or things I enjoy doing or want to do.
While I am making progress and I am learning to manage my emotions, or at least learning to learn how to do so, I am still in difficult territory, surrounded by alligators and fish with sharp teeth and gigantic mosquitoes and roaches (I'm being metaphorical here, although it looks literal, given that I'm in Houston). I still have habits to beat into submission and mental routines to reroute. I can't just give in to bad habits, especially the one that makes me unconscious for 3 or 4 hours at a time.
In cognitive-behavioral therapy, we substitute rational language and thinking for that which is broken. For example, irrational and broken thinking and self-talk might be "I shouldn't be unemployed. I hate it! It's horrible! What am I going to do?" And then it just ramps up from there. Rational substitutions could be "I don't like be unemployed. I want to work. It's uncomfortable and I feel afraid. I'm going to go look for work now."