To 'detect' a library you literally just add a Steam library folder as library. It takes all of 5 seconds, instantly detects and 'repairs' all the games. Again I have added the several hundred games, spanning 6 drives, over a dozen steam reinstalls and this process takes all of 2 minutes to do for each OS reinstall. More @Wikipedia
Hover over any link to get a description of the article. Please note that search keywords are sometimes hidden within the full article and don't appear in the description or title.