How do I power through work? How can I make sure that I don't get pulled into a tangent thought and procrastinate? There is lots of common advice to these questions, so let's start there.
Change your environment
I'm sure you can relate. Something inspired you a few days ago or maybe it was last week. You're ready to get things done now. You begin by eliminate distractions: you clean the room, you go to a cafe, or you get some very good headphones. Does it work? Maybe, but usually not. Those headphones might help but what's to keep you from opening up a new internet tab and watching a youtube video? That productivity cafe is starting to get expensive. Plus you have stuff at home or at the office that you need and you just don't want to lug it with you. So you try cleaning. If everything is in it's place it wont be a distraction, right? So you do that. You clean the room, office, and get things nicely sorted--if you're able to stay focused on the end goal without getting distracted. Cleaning has now used up some precious energy. You didn't have a lot of energy to begin with. After all, you aren't all that passionate about this thing your trying to get done.
Work on your habits
Ok, so the trick is to increase our energy levels and try to establish routines. I read once that our mental stamina is just like any other muscle. It's a muscle we train by exercising self control. We resist the morning coffee, buying that thing in your amazon shopping cart, and maybe even giving meditation a go. You spent a whole month opening doors with your less dominant hand. You figured out if you're a morning or an evening person; you work in precise windows because if you miss that productivity window, you're SOL. I'm not dismissing this advice; it really does work. It just doesn't work fast and it doesn't help you right now. The problem with the above shortcuts is that you will spend, like I have, years trying to perfect your flow without ever getting to real productivity.
Identify an internal drive
The next best thing is to develop a drive, a reason for the work that you're doing. This is what I believe to be the crux of Tony Robbins' gospel. Why are you doing this? What's your internal drive? Are you trying to to feed your family, to make someone else happy, because it's a required stepping stone to your long term plan for happiness? Who knows? Regardless of the incentive, there will be days that you will forget the why. You aren't a monk; your brain will easily fabricate an excuse: from physical exhaustion, lack of time, or procrastination. Most of life's work cannot be justified without a strong why. Are we doing laundry for our own sake? Why do we pay taxes? Why do we have to read through the next 700 pages of an SDK?
You need to rely on simple grit and perseverance. It's how the vast majority of the world, from farmers to construction workers, operate. They just "do." For a restless mind, it's difficult to "just do". I have developed two mantras I recite to myself. When I was kid, I first saw the "Anything you can do I can do better" commercial, and it stuck with me. Now every time I compete, be it an athletic event or a professional, I begin to run low on stamina. I don't think I have anything more to give. I just start repeating to myself "anything you can do .... (heavy breathing) ... I can do better". That's how I've finished numerous Spartan races, and managed to get through some of the hardest times in my life. The mantra makes my mind go blank and I just execute. Other times, I'm not really competing with anyone, in which case I fall back to "Power through, power through, power through". It has the same affect. I simply keep going, I give it more than I think I have by not thinking about what's left in the tank. I don't think about the why, and I don't think about how I can be more efficient. These mantras reflect that aspect of my personality. They aren't particularly inspirational, and they probably don't mean much to you. Figure out what yours is and give it a try.
I am not saying that you shouldn't work smart. Think before you start. Strategize. Yet, when the time comes, execute.