Как прочитать все файлы с другим расширением (скажем, .txt, .yml, et c) из репозитория GitLab?
Я использую GitLabApi
, ниже приведен код, который Я сделал до сих пор. Это в основном выборка одного файла.
public class GitLabRepoService {
@Value("${gitlab.accessToken}")
private String strAccessToken;
@Value("${gitlab.perfScript.projectId}")
private String strProjectId;
public RepositoryFile readFilesFromGitLabRepo(String hostUrl,String fileName,String strBranch) throws Exception {
GitLabApi gitLabApi = new GitLabApi(hostUrl, strAccessToken);
gitLabApi.setIgnoreCertificateErrors(true);
gitLabApi.getRepositoryFileApi().
return gitLabApi.getRepositoryFileApi().getFile(strProjectId, fileName, strBranch);
}
}