Instead of creating a VCS repo like this, I think it should pick one by name (the repositories array can be a json object with names for every repo), number (zero based if you used a plain array for repos) or maybe if you give an url that it looks in the original definition for a repo with the given URL. Otherwise some settings might be lost, not everyone defines their repo with only vcs+url.