Dough Git

commit

Use isATracker branding throughout the project

commit
f80db39f9996f992bab83c3f04f08d2afab69218
author
Clove Twilight <[email protected]>
date
2026-11-21 13:19
Preserve compatibility with existing GitHub review markers and update the runit log directory.

Co-Authored-By: Sandrone <[email protected]>

diff --git a/README.md b/README.md
index e441dc1..2172682 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,4 @@
-# is-a-tracker
+# isATracker
 
 A personal moderation assistant for pull requests on `is-a-dev/register` and
 `free-domains/is-a.bot`. Set the list in `GITHUB_REPOS` (comma separated, `owner/name`).
@@ -146,7 +146,7 @@ deno task lint
 The `deploy` folder is a runit service, laid out like the one in the `web` project.
 
 - `deploy/run` starts the built app as `clove` from `/srv/clove/isATracker` on port 3101.
-- `deploy/log/run` sends its output to `/var/log/is-a-tracker` through `svlogd`.
+- `deploy/log/run` sends its output to `/var/log/isATracker` through `svlogd`.
 
 The server folder needs `build/`, `node_modules/`, `config/`, `package.json` and `.env`.
 It also needs a `data/` folder that `clove` can write to; the SQLite file lives there.
diff --git a/deploy/log/run b/deploy/log/run
index f50e383..faabaaf 100755
--- a/deploy/log/run
+++ b/deploy/log/run
@@ -1,9 +1,9 @@
 #!/bin/sh
 # deploy/log/run
 # MIT — (c) Doughmination System®
-# runit log service for is-a-tracker: everything the app prints ends up here,
+# runit log service for isATracker: everything the app prints ends up here,
 # timestamped and rotated by svlogd
-LOG_DIR=/var/log/is-a-tracker
+LOG_DIR=/var/log/isATracker
 
 mkdir -p "$LOG_DIR"
 exec svlogd -tt "$LOG_DIR"
diff --git a/package.json b/package.json
index 59489eb..39c2f1b 100644
--- a/package.json
+++ b/package.json
@@ -1,5 +1,5 @@
 {
-	"name": "is-a-tracker",
+	"name": "isATracker",
 	"version": "0.0.1",
 	"private": true,
 	"license": "MIT",
diff --git a/src/lib/server/github/client.ts b/src/lib/server/github/client.ts
index 928fca6..1a0ce0e 100644
--- a/src/lib/server/github/client.ts
+++ b/src/lib/server/github/client.ts
@@ -120,7 +120,7 @@ function buildUrl(request: GitHubRequest): string {
 function buildHeaders(request: GitHubRequest): Headers {
 	const headers = new Headers({
 		Accept: request.accept ?? 'application/vnd.github+json',
-		'User-Agent': 'is-a-tracker',
+		'User-Agent': 'isATracker',
 		'X-GitHub-Api-Version': '2022-11-28'
 	});
 
diff --git a/src/lib/server/moderation/executors.ts b/src/lib/server/moderation/executors.ts
index 09d2197..91fbbdb 100644
--- a/src/lib/server/moderation/executors.ts
+++ b/src/lib/server/moderation/executors.ts
@@ -87,10 +87,11 @@ async function closeWithPolicyComment(input: ExecutorInput): Promise<ActionOutco
 }
 
 function reviewMarker(finding: { ruleId: string; filePath: string }): string {
-	return `<!-- is-a-tracker:${finding.ruleId}:${finding.filePath} -->`;
+	return `<!-- isATracker:${finding.ruleId}:${finding.filePath} -->`;
 }
 
-const markerPattern = /<!-- is-a-tracker:([^:]+):(.+?) -->/g;
+// Recognize reviews posted before the project was renamed.
+const markerPattern = /<!-- (?:isATracker|is-a-tracker):([^:]+):(.+?) -->/g;
 
 function reviewMessages(finding: FindingRow) {
 	const messages = getMessages();
@@ -116,7 +117,9 @@ async function requestRuleChanges(input: ExecutorInput): Promise<ActionOutcome>
 			review.user?.login === login &&
 			review.state === 'CHANGES_REQUESTED' &&
 			review.commit_id === headSha &&
-			markers.every((marker) => (review.body ?? '').includes(marker))
+			markers.every((marker) =>
+				(review.body ?? '').replaceAll('is-a-tracker:', 'isATracker:').includes(marker)
+			)
 	);
 
 	if (duplicate) {
diff --git a/src/lib/server/moderation/pipeline.test.ts b/src/lib/server/moderation/pipeline.test.ts
index e0c247a..169210c 100644
--- a/src/lib/server/moderation/pipeline.test.ts
+++ b/src/lib/server/moderation/pipeline.test.ts
@@ -17,6 +17,8 @@ import { getModerationStats, searchActions } from '../db/auditLog.ts';
 import { listFindingsForPullRequest } from '../db/findings.ts';
 import { performModerationAction } from './actions.ts';
 import { scanOnce } from './scanner.ts';
+import { executors } from './executors.ts';
+import { getPullRequest } from '../github/pullRequests.ts';
 
 interface FakePullRequest {
 	number: number;
@@ -535,4 +537,37 @@ describe('moderation pipeline', () => {
 			listFindingsForPullRequest(repo, 7).every((finding) => finding.status === 'actioned')
 		);
 	});
+
+	test('both review marker names prevent duplicate change requests', async () => {
+		const pullRequest = await getPullRequest(repo, 4);
+		const finding = findingFor(4);
+
+		for (const name of ['isATracker', 'is-a-tracker']) {
+			const review = {
+				method: 'POST',
+				path: '/pulls/4/reviews',
+				body: {
+					commit_id: pullRequest.headSha,
+					body: `<!-- ${name}:${finding.ruleId}:${finding.filePath} -->`
+				}
+			};
+
+			writes.push(review);
+
+			const outcome = await executors.requestChanges({
+				pullRequest,
+				findings: [finding],
+				evaluation: {
+					pullRequest,
+					files: [],
+					violations: [],
+					skippedFileCount: 0
+				}
+			});
+
+			assert.equal(outcome.status, 'skipped');
+			assert.equal(writes.at(-1), review);
+			writes.pop();
+		}
+	});
 });
diff --git a/src/routes/+layout.svelte b/src/routes/+layout.svelte
index a2c4250..95f53b3 100644
--- a/src/routes/+layout.svelte
+++ b/src/routes/+layout.svelte
@@ -40,7 +40,7 @@
 {#if data.showNavigation}
 	<header>
 		<nav class="page">
-			<strong>is-a-tracker</strong>
+			<strong>isATracker</strong>
 
 			{#each links.filter((link) => link.href !== '/pending' || data.authenticated) as link (link.href)}
 				<a href={link.href} aria-current={page.url.pathname === link.href ? 'page' : undefined}>
diff --git a/src/routes/+page.svelte b/src/routes/+page.svelte
index d0b235b..36ead47 100644
--- a/src/routes/+page.svelte
+++ b/src/routes/+page.svelte
@@ -32,7 +32,7 @@
 </script>
 
 <svelte:head>
-	<title>Overview · is-a-tracker</title>
+	<title>Overview · isATracker</title>
 </svelte:head>
 
 <h1>Moderation overview</h1>
diff --git a/src/routes/history/+page.svelte b/src/routes/history/+page.svelte
index 8dd4d3a..906cae2 100644
--- a/src/routes/history/+page.svelte
+++ b/src/routes/history/+page.svelte
@@ -20,7 +20,7 @@
 </script>
 
 <svelte:head>
-	<title>History · is-a-tracker</title>
+	<title>History · isATracker</title>
 </svelte:head>
 
 <h1>Moderation history</h1>
diff --git a/src/routes/login/+page.svelte b/src/routes/login/+page.svelte
index 5b591ba..c9519d7 100644
--- a/src/routes/login/+page.svelte
+++ b/src/routes/login/+page.svelte
@@ -9,7 +9,7 @@
 </script>
 
 <svelte:head>
-	<title>Sign in · is-a-tracker</title>
+	<title>Sign in · isATracker</title>
 </svelte:head>
 
 <h1>Moderator sign in</h1>
diff --git a/src/routes/lookup/+page.svelte b/src/routes/lookup/+page.svelte
index e74ddc3..5882cc3 100644
--- a/src/routes/lookup/+page.svelte
+++ b/src/routes/lookup/+page.svelte
@@ -11,7 +11,7 @@
 </script>
 
 <svelte:head>
-	<title>Lookup · is-a-tracker</title>
+	<title>Lookup · isATracker</title>
 </svelte:head>
 
 <h1>Manual PR lookup</h1>
diff --git a/src/routes/pending/+page.svelte b/src/routes/pending/+page.svelte
index f7087b8..39593b4 100644
--- a/src/routes/pending/+page.svelte
+++ b/src/routes/pending/+page.svelte
@@ -26,7 +26,7 @@
 </script>
 
 <svelte:head>
-	<title>Pending · is-a-tracker</title>
+	<title>Pending · isATracker</title>
 </svelte:head>
 
 <h1>Pending reviews</h1>