mirror of
https://github.com/anomalyco/opencode.git
synced 2026-05-25 05:44:37 +00:00
ci: "fix: exempt team members from compliance cleanup" (#28865)
This commit is contained in:
@@ -15,11 +15,8 @@ const cutoff = new Date(Date.now() - days * 24 * 60 * 60 * 1000)
|
||||
type Issue = {
|
||||
number: number
|
||||
updated_at: string
|
||||
author_association: string
|
||||
}
|
||||
|
||||
const teamAssociations = new Set(["OWNER", "MEMBER", "COLLABORATOR"])
|
||||
|
||||
const headers = {
|
||||
Authorization: `Bearer ${token}`,
|
||||
"Content-Type": "application/json",
|
||||
@@ -66,10 +63,6 @@ async function main() {
|
||||
for (const i of all) {
|
||||
const updated = new Date(i.updated_at)
|
||||
if (updated < cutoff) {
|
||||
if (teamAssociations.has(i.author_association)) {
|
||||
console.log(`Skipping #${i.number}: author association is ${i.author_association}`)
|
||||
continue
|
||||
}
|
||||
stale.push(i.number)
|
||||
} else {
|
||||
console.log(`\nFound fresh issue #${i.number}, stopping`)
|
||||
|
||||
Reference in New Issue
Block a user