Skip to content

Commit 164f05d

Browse files
Merge pull request #1170 from merico-dev/ghreponame
fix: added org as prefix to github repo name
2 parents 5947732 + 363a708 commit 164f05d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

plugins/github/tasks/github_repo_converter.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ package tasks
22

33
import (
44
"fmt"
5+
56
lakeModels "github.com/merico-dev/lake/models"
67
"github.com/merico-dev/lake/models/domainlayer"
78
"github.com/merico-dev/lake/models/domainlayer/code"
@@ -36,12 +37,13 @@ func ConvertRepos() error {
3637

3738
return nil
3839
}
40+
3941
func convertToRepositoryModel(repository *githubModels.GithubRepo) *code.Repo {
4042
domainRepository := &code.Repo{
4143
DomainEntity: domainlayer.DomainEntity{
4244
Id: didgen.NewDomainIdGenerator(repository).Generate(repository.GithubId),
4345
},
44-
Name: repository.Name,
46+
Name: fmt.Sprintf("%s/%s", repository.OwnerLogin, repository.Name),
4547
Url: repository.HTMLUrl,
4648
Description: repository.Description,
4749
ForkedFrom: repository.ParentHTMLUrl,
@@ -51,6 +53,7 @@ func convertToRepositoryModel(repository *githubModels.GithubRepo) *code.Repo {
5153
}
5254
return domainRepository
5355
}
56+
5457
func convertToBoardModel(repository *githubModels.GithubRepo, domainIdGenerator *didgen.DomainIdGenerator) *ticket.Board {
5558
domainBoard := &ticket.Board{
5659
DomainEntity: domainlayer.DomainEntity{

0 commit comments

Comments
 (0)