Question: Add team for CODEOWNERS from other organization #21781
-
Hi, In documentation there is information that teams can be assigned in CODEOWNERS file.
as we can see there is format @org/team-name. That means that I can assign team from different organization? Example, org Foo has only team definition: Org: Foo Teams: A,B,C Org Bar has only repos with teams codeowners from Foo organization Org: Bar Repository: XYZ: with CODEOWNERS:
Thanks in advance for your reply :) Cheers, Mateusz |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 2 replies
-
Thank you @mszostok for being here and for your excellent question! Although @org/team-name is apart of the permitted syntax for adding CODEOWNERS, teams are per organization and code owners are per repository. So there is presently no cross-over in allowing CODEOWNER access from one organization’s team to another organization using that assigning syntax. You would need to configure a team per organization to encompass the users that you wish to have as CODEOWNER per repository. |
Beta Was this translation helpful? Give feedback.
-
I too would love to have this feature. It was also asked for in isaacs/github#953 |
Beta Was this translation helpful? Give feedback.
-
4years later, I encountered the same confusion on what the syntax says is possible:
Vs what was explained here - Teams from different orgs can't be mentioned in CODEOWNERS. May be it is time to update the doc to explicitly call that out... |
Beta Was this translation helpful? Give feedback.
-
@nyahbhinghiPrincess It would make sense to allow this for enterprise accounts with many orgs. |
Beta Was this translation helpful? Give feedback.
Thank you @mszostok for being here and for your excellent question! Although @org/team-name is apart of the permitted syntax for adding CODEOWNERS, teams are per organization and code owners are per repository. So there is presently no cross-over in allowing CODEOWNER access from one organization’s team to another organization using that assigning syntax.
You would need to configure a team per organization to encompass the users that you wish to have as CODEOWNER per repository.