try {
BlobBasedConfig config = new BlobBasedConfig(repository.getConfig(), blob);
for (String module : config.getSubsections("submodule")) {
String path = config.getString("submodule", module, "path");
String url = config.getString("submodule", module, "url");
list.add(new SubmoduleModel(module, path, url));
}
} catch (ConfigInvalidException e) {
LOGGER.error("Failed to load .gitmodules file for " + repository.getDirectory(), e);
}
return list;