Watch the Legato Exercise 3 online guitar lesson by Jeff McErlain from Beginner Blues-Rock Soloing
So how do we practice? Once you set aside the time, choose one idea, lick, or exercise to work on. Work on that alone. A great piece of advice given to me by teacher years ago was to have a countdown timer (there is one on your smartphone), as part of your practice. Set the timer for three minutes and practice that one thing for three minutes. If you're attention starts to wander during that time, and believe me it will, gently refocus it on the task. Once that three minutes is up, take a three-minute break and do whatever you would like. Then repeat. I found this to be extremely effective for me as a person who has difficulty focusing for long periods of time.
On a side note, if you were practicing something that is technically demanding and your hand starts to get tired, take a break immediately. Three straight minutes of shredding is not necessarily a good idea for your muscles!