Implementing excluded sources for repo/* configurations, and cleaned up discovery impl a little more.