The open source coding agent.
TypeScript
fix: update workflows for better automation (#14809)
Ryan Vogel24c63914bf9f
diff --git a/.github/workflows/compliance-close.yml b/.github/workflows/compliance-close.ymlindex 5b424d0adfa..c3bcf9f686f 100644--- a/.github/workflows/compliance-close.yml+++ b/.github/workflows/compliance-close.yml@@ -65,6 +65,15 @@ jobs:body: closeMessage,});+ try {+ await github.rest.issues.removeLabel({+ owner: context.repo.owner,+ repo: context.repo.repo,+ issue_number: item.number,+ name: 'needs:compliance',+ });+ } catch (e) {}+if (isPR) {await github.rest.pulls.update({owner: context.repo.owner,diff --git a/.github/workflows/pr-standards.yml b/.github/workflows/pr-standards.ymlindex 27581d06b76..1edbd5d061d 100644--- a/.github/workflows/pr-standards.yml+++ b/.github/workflows/pr-standards.yml@@ -108,11 +108,11 @@ jobs:await removeLabel('needs:title');- // Step 2: Check for linked issue (skip for docs/refactor PRs)- const skipIssueCheck = /^(docs|refactor)\s*(\([a-zA-Z0-9-]+\))?\s*:/.test(title);+ // Step 2: Check for linked issue (skip for docs/refactor/feat PRs)+ const skipIssueCheck = /^(docs|refactor|feat)\s*(\([a-zA-Z0-9-]+\))?\s*:/.test(title);if (skipIssueCheck) {await removeLabel('needs:issue');- console.log('Skipping issue check for docs/refactor PR');+ console.log('Skipping issue check for docs/refactor/feat PR');return;}const query = `@@ -189,7 +189,7 @@ jobs:const body = pr.body || '';const title = pr.title;- const isDocsOrRefactor = /^(docs|refactor)\s*(\([a-zA-Z0-9-]+\))?\s*:/.test(title);+ const isDocsRefactorOrFeat = /^(docs|refactor|feat)\s*(\([a-zA-Z0-9-]+\))?\s*:/.test(title);const issues = [];@@ -225,8 +225,8 @@ jobs:}}- // Check: issue reference (skip for docs/refactor)- if (!isDocsOrRefactor && hasIssueSection) {+ // Check: issue reference (skip for docs/refactor/feat)+ if (!isDocsRefactorOrFeat && hasIssueSection) {const issueMatch = body.match(/### Issue for this PR\s*\n([\s\S]*?)(?=###|$)/);const issueContent = issueMatch ? issueMatch[1].trim() : '';const hasIssueRef = /(closes|fixes|resolves)\s+#\d+/i.test(issueContent) || /#\d+/.test(issueContent);