I've recently rediscovered a "focus hack" I used to use before my days as a software developer. It's a simple little thing, and it's far from original. Tons of people do this. I simply went years without doing it and have only just gotten back into the habit.
You keep a pen and paper on your desk. When you feel your mind wandering, or you start to feel somewhat overwhelmed with all you need to do, you write down the next thing that needs to be taken care of. You don't make a list of all you need to do. You don't make a sub-list of items you need to do to accomplish the next thing. You simply write a quick statement of what you'll be doing next.
There's some power in simply commiting it to paper. I don't necessarily even glance at what I've written afterwards -- it's more the act of writing it. It centers my mind on the task at hand.
After paternity leave I came back to a development team right in the middle of a big project. I was there at the start. However, I've found being part of the initial work scaffolding the project, then disappearing and finally reappearing after so much time has left me feeling emotionally and intellectually distant from the work. This might sound a bit the way people describe "burnout", but while the symptoms may be similar the cause is almost the opposite.
In any event, using this focus hack has proven helpful. It's another way of putting one foot in front of the other.