deployment-info.json: Report the submodules of every checkout

Collect the git information for each staged checkout and its submodules,
recursively, and group it by MediaWiki version. w/deployment-info.php then
answers a request with only the checkouts of the version that the requested
wiki runs.

A submodule is reported at the commit that the public commit of its parent
records, so a security patch that is applied in a submodule is not reported.
The branch of the parent is reported for a submodule only when the commit of
the submodule is on that branch, because some submodules are libraries that
have no branch of the train.

cache_git_info() returns the information that it collects, so the walk of the
MediaWiki version directories happens once per deployment. The walk now also
covers vendor and the submodules of submodules.

Bug: T434726

Merge request reports

Loading