mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-02-01 14:44:29 +00:00
fix(workflow): update maintainer check logic to be inclusive and case-insensitive (#18009)
This commit is contained in:
@@ -48,14 +48,15 @@ jobs:
|
|||||||
org: context.repo.owner,
|
org: context.repo.owner,
|
||||||
team_slug: 'gemini-cli-maintainers'
|
team_slug: 'gemini-cli-maintainers'
|
||||||
});
|
});
|
||||||
maintainerLogins = new Set(members.map(m => m.login));
|
maintainerLogins = new Set(members.map(m => m.login.toLowerCase()));
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
core.warning('Failed to fetch team members');
|
core.warning('Failed to fetch team members');
|
||||||
}
|
}
|
||||||
|
|
||||||
const isMaintainer = (login, assoc) => {
|
const isMaintainer = (login, assoc) => {
|
||||||
if (maintainerLogins.size > 0) return maintainerLogins.has(login);
|
const isTeamMember = maintainerLogins.has(login.toLowerCase());
|
||||||
return ['OWNER', 'MEMBER', 'COLLABORATOR'].includes(assoc);
|
const isRepoMaintainer = ['OWNER', 'MEMBER', 'COLLABORATOR'].includes(assoc);
|
||||||
|
return isTeamMember || isRepoMaintainer;
|
||||||
};
|
};
|
||||||
|
|
||||||
// 2. Determine which PRs to check
|
// 2. Determine which PRs to check
|
||||||
|
|||||||
Reference in New Issue
Block a user