Autodetect more than github repository, using a more generic heuristic (...

... see #8937 )