Migrate to prjgit based config
config now only has reference to org or prjgits and the rest is defined in the "workflow.config" in the prjgit itself. This allows the config to be updated in the project.
This commit is contained in:
@@ -479,8 +479,11 @@ func (gitea *GiteaTransport) AddReviewComment(pr *models.PullRequest, state mode
|
||||
}
|
||||
|
||||
func (gitea *GiteaTransport) GetRepositoryFileContent(org, repo, hash, path string) ([]byte, string, error) {
|
||||
content, err := gitea.client.Repository.RepoGetContents(
|
||||
repository.NewRepoGetContentsParams().WithOwner(org).WithRepo(repo).WithFilepath(path).WithRef(&hash),
|
||||
params := repository.NewRepoGetContentsParams().WithOwner(org).WithRepo(repo).WithFilepath(path)
|
||||
if len(hash) > 0 {
|
||||
params = params.WithRef(&hash)
|
||||
}
|
||||
content, err := gitea.client.Repository.RepoGetContents(params,
|
||||
gitea.transport.DefaultAuthentication,
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user