I need to get all the .hcl files from the master branch of a GIT repository. Since those files will be created by users, my source code doesn’t know the names/paths of those files. This is why I’m looking a way to get all the files that I have in my repository’s subfolders.
However in the documentation there is only a way to get one specific file by giving the file_path.
GET /projects/:id/repository/files/:file_path
I need something like this:
GET /projects/:id/repository/files?branch=master[fromAllFolders][*.hcl]
This is the dictionary tree in my repository, that I’m trying to access:
dev (folder)
- global-management.hcl
- test-token_1.hcl
- another.hcl
Int (folder)
- global-management.hcl
- test-token_2.hcl
- another.hcl
val (folder)
- global-management.hcl
- test-token_3.hcl
- another.hcl
prod (folder)
- global-management.hcl
- test-token_4.hcl
- another.hcl
Is there any way to make this possible? I would really appreciate any help!! Thanks in advance!!