Skip to content

Commit 94f1198

Browse files
Tajudeenclaude
andcommitted
phase9(ci): unblock Compile & Hygiene -- diff .d.ts + appimage hygiene ignore
Two pre-existing blockers (red on main too, NOT introduced by the branch) made the "Compile & Hygiene" CI job fail. Both fixed minimally: 1. core-ci/tsgo TS2307: findDiffs.ts imports the GENERATED ../react/out/diff/index.js. CI runs the typecheck BEFORE buildreact, so the artifact is absent and the module cannot resolve. The 6 sibling react/out modules already ship committed index.d.ts files (out/ is gitignored, they are force-added) -- diff/ was the only one missing one. Add a hand-maintained out/diff/index.d.ts (diffLines + Change) so the import is type-resolvable without building react, matching the existing pattern. tsup emits .js only (dts is disabled, clean:false) so a local buildreact will not clobber it. 2. hygiene: scripts/appimage/create_appimage.sh fails on (a) intentional translated (non-ASCII) desktop-menu names and (b) its own space indentation. Exclude it from unicodeFilter + indentationFilter in build/filters.ts (the same treatment build/**/*.sh and the cortexide React tree already get) rather than stripping the translations. Verification: - tsgo with react/out/diff/index.js hidden (exact CI condition: react unbuilt) -> 0 errors, no findDiffs error. Normal-state tsgo also 0. - node build/hygiene.ts scripts/appimage/create_appimage.sh -> exit 0 (was 14 errors). hygiene on the new .d.ts -> exit 0. - cortexide node subset: 551 passing, 0 failing. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent d929252 commit 94f1198

2 files changed

Lines changed: 27 additions & 0 deletions

File tree

‎build/filters.ts‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,10 @@ export const unicodeFilter = Object.freeze<string[]>([
6767
// extensions/copilot has its own code style
6868
'!extensions/copilot/**',
6969

70+
// CortexIDE AppImage packaging script embeds intentional translated (non-ASCII)
71+
// desktop-menu names (Japanese/Korean/Russian/Chinese "New Empty Window" etc.)
72+
'!scripts/appimage/create_appimage.sh',
73+
7074
'!src/vs/base/browser/dompurify/**',
7175
'!src/vs/workbench/services/keybinding/browser/keyboardLayouts/**',
7276
'!src/vs/workbench/contrib/terminal/common/scripts/psreadline/**',
@@ -143,6 +147,8 @@ export const indentationFilter = Object.freeze<string[]>([
143147
'!**/*.{svg,exe,png,bmp,jpg,scpt,bat,cmd,cur,ttf,woff,eot,md,ps1,psm1,template,yaml,yml,d.ts.recipe,ico,icns,plist,opus,admx,adml,wasm}',
144148
'!build/{lib,download,linux,darwin}/**/*.js',
145149
'!build/**/*.sh',
150+
// CortexIDE AppImage packaging script keeps its own (space) shell indentation
151+
'!scripts/appimage/create_appimage.sh',
146152
'!build/azure-pipelines/**/*.js',
147153
'!build/azure-pipelines/**/*.config',
148154
'!build/npm/gyp/custom-headers/*.patch',
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/*--------------------------------------------------------------------------------------
2+
* Copyright 2025 Glass Devtools, Inc. All rights reserved.
3+
* Licensed under the Apache License, Version 2.0. See LICENSE.txt for more information.
4+
*--------------------------------------------------------------------------------------*/
5+
6+
// Hand-maintained type declarations for the generated diff bundle
7+
// (browser/react/out/diff/index.js, produced by `npm run buildreact`). Committed
8+
// alongside the sibling react/out *.d.ts files (out/ is gitignored, these are force-added)
9+
// so the type checker can resolve `import { diffLines } from '../react/out/diff/index.js'`
10+
// in findDiffs.ts WITHOUT first building react -- CI runs the typecheck before buildreact.
11+
// The runtime impl re-exports diffLines/Change from the `diff` npm package
12+
// (see react/src/diff/index.tsx).
13+
14+
export interface Change {
15+
count?: number;
16+
value: string;
17+
added?: boolean;
18+
removed?: boolean;
19+
}
20+
21+
export declare function diffLines(oldStr: string, newStr: string): Change[];

0 commit comments

Comments
 (0)