build tree where missing and clone in repos