























@@ -1,11 +1,11 @@
11// Barnacle owns deterministic GitHub triage and auto-response behavior.
223-export const activePrLimit = 10;
3+const activePrLimit = 10;
4455const thirdPartyExtensionMessage =
66"Please publish this as a third-party plugin on [ClawHub](https://clawhub.ai) instead of adding it to the core repo. Docs: https://docs.openclaw.ai/plugin and https://docs.openclaw.ai/tools/clawhub";
778-export const rules = [
8+const rules = [
99{
1010label: "r: skill",
1111close: true,
@@ -159,7 +159,7 @@ export const candidateLabels = {
159159externalPluginCandidate: "triage: external-plugin-candidate",
160160};
161161162-export const bugSubtypeLabelSpecs = {
162+const bugSubtypeLabelSpecs = {
163163regression: {
164164color: "D93F0B",
165165description: "Behavior that previously worked and now fails",
@@ -251,15 +251,15 @@ const candidateActionRules = [
251251const normalizeLogin = (login) => login.toLowerCase();
252252const automationPrHeadPrefixes = ["clawsweeper/", "clownfish/"];
253253254-export function isAutomationPullRequest(pullRequest) {
254+function isAutomationPullRequest(pullRequest) {
255255const headRefName = pullRequest.headRefName ?? pullRequest.head?.ref ?? "";
256256return (
257257typeof headRefName === "string" &&
258258automationPrHeadPrefixes.some((prefix) => headRefName.startsWith(prefix))
259259);
260260}
261261262-export function extractIssueFormValue(body, field) {
262+function extractIssueFormValue(body, field) {
263263if (!body) {
264264return "";
265265}
@@ -281,17 +281,17 @@ export function extractIssueFormValue(body, field) {
281281return "";
282282}
283283284-export function hasLinkedReference(text) {
284+function hasLinkedReference(text) {
285285return /(?:#\d+|github\.com\/openclaw\/openclaw\/(?:issues|pull)\/\d+)/i.test(text);
286286}
287287288-export function hasFilledTemplateLine(body, field) {
288+function hasFilledTemplateLine(body, field) {
289289const escapedField = field.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
290290const regex = new RegExp(`^\\s*-\\s*${escapedField}:\\s*\\S`, "im");
291291return regex.test(body);
292292}
293293294-export function hasMostlyBlankTemplate(body) {
294+function hasMostlyBlankTemplate(body) {
295295if (!body) {
296296return true;
297297}
@@ -332,7 +332,7 @@ function stripPullRequestTemplateBoilerplate(text) {
332332);
333333}
334334335-export function hasConcreteBehaviorContext(body, text) {
335+function hasConcreteBehaviorContext(body, text) {
336336if (hasLinkedReference(text)) {
337337return true;
338338}
@@ -349,7 +349,7 @@ export function hasConcreteBehaviorContext(body, text) {
349349);
350350}
351351352-export function hasClearDesignContext(body, text) {
352+function hasClearDesignContext(body, text) {
353353if (hasConcreteBehaviorContext(body, text)) {
354354return true;
355355}
@@ -359,15 +359,15 @@ export function hasClearDesignContext(body, text) {
359359);
360360}
361361362-export function isMarkdownOrDocsFile(filename) {
362+function isMarkdownOrDocsFile(filename) {
363363return (
364364filename.startsWith("docs/") ||
365365/\.mdx?$/i.test(filename) ||
366366/(^|\/)(README|CHANGELOG|CONTRIBUTING|AGENTS|CLAUDE)\.md$/i.test(filename)
367367);
368368}
369369370-export function isTestLikeFile(filename) {
370+function isTestLikeFile(filename) {
371371return (
372372/(^|\/)(__tests__|fixtures?|snapshots?)(\/|$)/i.test(filename) ||
373373/(^|\/)test\/helpers\//i.test(filename) ||
@@ -377,7 +377,7 @@ export function isTestLikeFile(filename) {
377377);
378378}
379379380-export function isInfraLikeFile(filename) {
380+function isInfraLikeFile(filename) {
381381return (
382382/^\.github\/(?:workflows|actions)\//.test(filename) ||
383383filename.startsWith("scripts/") ||
@@ -390,7 +390,7 @@ export function isInfraLikeFile(filename) {
390390);
391391}
392392393-export function surfacesForFile(filename) {
393+function surfacesForFile(filename) {
394394const surfaces = new Set();
395395if (/\.generated\/|generated|\.snap$/i.test(filename)) {
396396surfaces.add("generated");
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。