Method: Gitlab::Git::Repository#submodules
- Defined in:
- lib/gitlab_git/repository.rb
#submodules(ref) ⇒ Object
Return hash with submodules info for this repository
Ex.
{
"rack" => {
"id" => "c67be4624545b4263184c4a0e8f887efd0a66320",
"path" => "rack",
"url" => "git://github.com/chneukirchen/rack.git"
},
"encoding" => {
"id" => ....
}
}
526 527 528 529 530 531 532 533 534 535 536 537 |
# File 'lib/gitlab_git/repository.rb', line 526 def submodules(ref) commit = rev_parse_target(ref) return {} unless commit begin content = blob_content(commit, ".gitmodules") rescue InvalidBlobName return {} end parse_gitmodules(commit, content) end |