Skip to content

Commit b69e34c

Browse files
committed
fix: pnpm lint
1 parent 48f5196 commit b69e34c

File tree

9 files changed

+58
-9
lines changed

9 files changed

+58
-9
lines changed

eslint.config.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import js from '@eslint/js';
22
import tseslint from 'typescript-eslint';
33
import eslintConfigPrettier from 'eslint-config-prettier';
44
import unusedImports from 'eslint-plugin-unused-imports';
5+
import reactHooks from 'eslint-plugin-react-hooks';
56
import globals from 'globals';
67

78
export default tseslint.config(
@@ -12,6 +13,7 @@ export default tseslint.config(
1213
{
1314
plugins: {
1415
'unused-imports': unusedImports,
16+
'react-hooks': reactHooks,
1517
},
1618
languageOptions: {
1719
globals: { ...globals.node, ...globals.browser },

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
"concurrently": "^9.1.0",
2424
"eslint": "^9.39.2",
2525
"eslint-config-prettier": "^10.1.8",
26+
"eslint-plugin-react-hooks": "^7.0.1",
2627
"eslint-plugin-unused-imports": "^4.4.1",
2728
"globals": "^17.3.0",
2829
"prettier": "^3.8.1",

packages/server/src/routes/repos.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ import {
88
scanRepoForAIFiles,
99
deriveStoreName,
1010
ensureDir,
11-
isSymlink,
1211
symlinkExists,
1312
} from '../services/repo-scanner.js';
1413
import { fileChecksum, symlinkChecksum } from '../services/checksum.js';

packages/server/src/routes/setup.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ export function registerSetupRoutes(app: FastifyInstance, state: AppState): void
7777
);
7878

7979
// Reset configuration — returns to setup mode
80-
app.post('/api/setup/reset', async (_req, reply) => {
80+
app.post('/api/setup/reset', async (_req, _reply) => {
8181
// Stop sync engine if running
8282
if (state.syncEngine) {
8383
await state.syncEngine.stop();

packages/server/src/services/__tests__/size-thresholds.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ describe('SyncEngine respects custom block threshold', () => {
273273
"INSERT INTO tracked_files (id, repo_id, relative_path, store_checksum, target_checksum, sync_status) VALUES ('tf-1', ?, ?, 'abc', 'abc', 'synced')",
274274
).run(REPO_ID, 'CLAUDE.md');
275275

276-
const result = await engine.syncRepo(REPO_ID);
276+
const _result = await engine.syncRepo(REPO_ID);
277277
// Should not be blocked
278278
const blockedEvents = broadcastedEvents.filter(
279279
(e: unknown) => (e as { type: string }).type === 'sync_blocked',
@@ -293,7 +293,7 @@ describe('SyncEngine respects custom block threshold', () => {
293293
db.prepare(
294294
"INSERT OR REPLACE INTO settings (key, value) VALUES ('size_blocked_mb', '999')",
295295
).run();
296-
const result1 = await engine.syncRepo(REPO_ID);
296+
const _result1 = await engine.syncRepo(REPO_ID);
297297
const blocked1 = broadcastedEvents.filter(
298298
(e: unknown) => (e as { type: string }).type === 'sync_blocked',
299299
);

packages/server/src/services/store-git.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ let git: SimpleGit | null = null;
1212

1313
// Batched commit state: accumulate messages and flush after a debounce window
1414
const COMMIT_DEBOUNCE_MS = 2000;
15-
let pendingMessages: string[] = [];
15+
const pendingMessages: string[] = [];
1616
let commitTimer: ReturnType<typeof setTimeout> | null = null;
1717
let flushPromise: Promise<void> | null = null;
1818

packages/ui/src/components/file-editor-layout.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ export function FileEditorLayout({
7777
} else {
7878
onSearchChange?.('');
7979
}
80-
}, [searchOpen]); // eslint-disable-line react-hooks/exhaustive-deps
80+
}, [searchOpen]);
8181

8282
return (
8383
<div className="grid gap-4 md:grid-cols-[2fr_3fr] grid-rows-[1fr] flex-1 min-h-0 overflow-hidden">

packages/ui/src/pages/repo-detail.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ function DetailPage({ type }: { type: 'repo' | 'service' }) {
205205
() => {},
206206
);
207207
}
208-
}, [fileMap]); // eslint-disable-line react-hooks/exhaustive-deps
208+
}, [fileMap]);
209209

210210
// Auto-refresh conflict detail / file content when files change on disk
211211
const selectedFileRef = useRef<string | null>(null);
@@ -283,7 +283,7 @@ function DetailPage({ type }: { type: 'repo' | 'service' }) {
283283
unsubSync();
284284
unsubResolved();
285285
};
286-
}, [id]); // eslint-disable-line react-hooks/exhaustive-deps
286+
}, [id]);
287287

288288
const largestPaths = useMemo(() => computeLargestPaths(target?.files ?? []), [target?.files]);
289289

@@ -462,7 +462,7 @@ function DetailPage({ type }: { type: 'repo' | 'service' }) {
462462
toast.error(err instanceof Error ? err.message : 'Failed to delete file');
463463
}
464464
},
465-
[id, selectedFile, target?.files, refetch], // eslint-disable-line react-hooks/exhaustive-deps
465+
[id, selectedFile, target?.files, refetch],
466466
);
467467

468468
const handleIgnore = useCallback(

pnpm-lock.yaml

Lines changed: 47 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)