When I program, I often get too involved with details. There might be some little thing that doesn't do exactly what I want it to, or maybe there's some little feature I want to add. Either way, none are really essential to the application - it's just a minor niusance (if any). However, when trying to fix it, I may happen to spend way more time on it than I planned, and there are things much more important that I should be doing instead of dealing with this little detail.
What can I do to avoid getting carried away with details, when there's more essential things that need doing?
(I didn't know how to tag this question, so feel free to add whatever appropriate tags that are missing.)