Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
aceaa40
feat: add update notification system similar to Cursor
Nov 19, 2025
02f02d4
fix: update all void URLs to use opencortexide organization
Nov 19, 2025
9d8a7cb
Fix module resolution errors for Electron imports and workbench modules
Nov 21, 2025
ce93ea9
WIP: Various improvements and updates
Nov 21, 2025
1e16542
Fix rendering performance bug: optimize markdown parsing and streamin…
Nov 21, 2025
a60d20c
Fix: Only log timing metrics when values are valid (>= 0)
Nov 21, 2025
c199155
Fix: Remove unavailable Gemini model and improve error handling
Nov 21, 2025
d35ee5b
Update Gemini models list with latest available models (Nov 2025)
Nov 21, 2025
96a9721
Update all model lists with latest available models (Nov 2025)
Nov 21, 2025
4ebcfd9
Add automatic fallback for Gemini 3.0 models when unavailable
Nov 22, 2025
329afa6
Fix broken path reference in comment (void/src/vs/base/common/marshal…
Nov 22, 2025
8c78a75
Fix production build: Copy React components to out-build/ directory
Nov 22, 2025
fab81a7
Add React components to production build resources
Nov 22, 2025
53a2318
Fix documentation: Correct voidSettingsPane.ts to cortexideSettingsPa…
Nov 22, 2025
dcc0d1d
Fix TypeScript compilation errors in cortexideCommandBarService
Nov 22, 2025
f2666e8
Fix React build: Keep chunk imports relative for ES module compatibility
Nov 23, 2025
32a4cf6
Add Visual C++ Redistributables check to Windows installer
Nov 23, 2025
dab9952
Automatically install Visual C++ Redistributables during setup
Nov 23, 2025
5868aae
macOS: Add blank screen prevention fix
Nov 23, 2025
4ead0e1
Fix Linux build issues for alternative architectures
Nov 23, 2025
85acc77
Fix React version mismatch and bootstrap ESM compatibility
Nov 23, 2025
b5e7cba
Fix InnoSetup Check parameter syntax error
Nov 23, 2025
8c73711
Add React build file verification to prevent blank screen issue
Nov 23, 2025
cf20dd8
Fix blank screen issue: Remove hardcoded React chunk names from impor…
Nov 23, 2025
8b8b850
Fix blank screen issues: Add comprehensive error handling
Nov 23, 2025
abaf637
Add error handling to remaining React mount points
Nov 23, 2025
a5da9c4
Fix Windows installer CreateProcess error and improve macOS blank scr…
Nov 23, 2025
255934a
Fix InnoSetup syntax error in Run section Check parameter
Nov 23, 2025
d7f3af6
Fix macOS blank screen with comprehensive window visibility handling
Nov 23, 2025
692821c
Add error handling and diagnostics for macOS blank screen fix
Nov 23, 2025
69681ab
Add comprehensive fixes for remaining macOS blank screen issues
Nov 23, 2025
ab865fb
Fix TypeScript compilation error: remove invalid gpu-process-crashed …
Nov 23, 2025
f8065ea
Fix InnoSetup compilation error: inline Check logic on line 114
Nov 23, 2025
1f4b255
Fix Windows installer launch path - add skipifdoesntexist flag to pre…
Nov 23, 2025
518a3dc
Fix Inno Setup installer script and improve executable verification
Nov 23, 2025
0023c3d
fix(macOS): Add diagnostics for blank screen and reduce update servic…
Nov 23, 2025
f05e803
Fix Windows build: Replace Arch constant comparison with runtime func…
Nov 23, 2025
743d331
Update package-lock.json to sync with package.json for npm ci compati…
Nov 24, 2025
39c4877
Fix TypeScript deprecation: add ignoreDeprecations for allowSynthetic…
Nov 24, 2025
ff15bb5
Fix blank screen: Add vscode-bootstrapImportMap to CSP trusted-types …
Nov 24, 2025
f8c9e9a
Apply version-1-update.patch: Update auto-update URL format for corte…
Nov 24, 2025
4e2b20c
fix: make windows installer target actual exe
Nov 24, 2025
d96370c
update version
Nov 24, 2025
bdbc66c
feat: Tích hợp lõi tác nhân AI làm dịch vụ Workbench gốc
google-labs-jules[bot] Nov 25, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CORTEXIDE_CODEBASE_GUIDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ This guide orients you to key areas changed or added for CortexIDE.
- Linux packaging: `resources/linux/cortex.desktop`, `cortex-url-handler.desktop`, `cortex.appdata.xml`
- Provider configs: `resources/provider-config.example.json`
- LLM wiring: `src/vs/workbench/contrib/cortexide/*/llm*` (providers, settings, services)
- Settings UI: `src/vs/workbench/contrib/cortexide/browser/voidSettingsPane.ts`
- Settings UI: `src/vs/workbench/contrib/cortexide/browser/cortexideSettingsPane.ts`
- Chat and sidebar: `src/vs/workbench/contrib/cortexide/browser/sidebar*`

Note: Some internal identifiers may still use the `void` namespace in type names and interfaces for backward compatibility, but the folder structure uses `cortexide`.
54 changes: 53 additions & 1 deletion build/gulpfile.compile.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,56 @@ const util = require('./lib/util');
const date = require('./lib/date');
const task = require('./lib/task');
const compilation = require('./lib/compilation');
const { execSync } = require('child_process');
const path = require('path');

/**
* Task to build React components for production
*/
const buildReactTask = task.define('build-react', () => {
return new Promise((resolve, reject) => {
try {
const reactBuildPath = path.join(__dirname, '../src/vs/workbench/contrib/cortexide/browser/react');
// allow-any-unicode-next-line
console.log('🔨 Building React components...');
execSync('node build.js', {
cwd: reactBuildPath,
stdio: 'inherit'
});
// allow-any-unicode-next-line
console.log('✅ React components built successfully');
resolve();
} catch (error) {
// allow-any-unicode-next-line
console.error('❌ Error building React components:', error);
reject(error);
}
});
});

/**
* Task to verify React build files exist after compilation
*/
const verifyReactBuildTask = task.define('verify-react-build', () => {
const fs = require('fs');
const path = require('path');
const reactOutPath = path.join(__dirname, '../out-build/vs/workbench/contrib/cortexide/browser/react/out');

if (!fs.existsSync(reactOutPath)) {
throw new Error(`React build output directory does not exist: ${reactOutPath}`);
}

const files = fs.readdirSync(reactOutPath);
const jsFiles = files.filter(f => f.endsWith('.js'));

if (jsFiles.length === 0) {
throw new Error(`No React build files found in ${reactOutPath}. Expected at least one .js file.`);
}

// allow-any-unicode-next-line
console.log(`✅ Verified ${jsFiles.length} React build files exist in out-build/`);
return Promise.resolve();
});

/**
* @param {boolean} disableMangle
Expand All @@ -20,7 +70,9 @@ function makeCompileBuildTask(disableMangle) {
util.rimraf('out-build'),
date.writeISODate('out-build'),
compilation.compileApiProposalNamesTask,
compilation.compileTask('src', 'out-build', true, { disableMangle })
buildReactTask, // Build React components before compiling
compilation.compileTask('src', 'out-build', true, { disableMangle }),
verifyReactBuildTask // Verify React files are preserved after compilation
);
}

Expand Down
26 changes: 23 additions & 3 deletions build/gulpfile.reh.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,9 +156,16 @@ function getNodeChecksum(expectedName) {

function extractAlpinefromDocker(nodeVersion, platform, arch) {
const imageName = arch === 'arm64' ? 'arm64v8/node' : 'node';
log(`Downloading node.js ${nodeVersion} ${platform} ${arch} from docker image ${imageName}`);
const contents = cp.execSync(`docker run --rm ${imageName}:${nodeVersion}-alpine /bin/sh -c 'cat \`which node\`'`, { maxBuffer: 100 * 1024 * 1024, encoding: 'buffer' });
return es.readArray([new File({ path: 'node', contents, stat: { mode: parseInt('755', 8) } })]);
const imageTag = `${imageName}:${nodeVersion}-alpine`;
log(`Downloading node.js ${nodeVersion} ${platform} ${arch} from docker image ${imageTag}`);
try {
// Use double quotes for the shell command and properly escape the which command
const contents = cp.execSync(`docker run --rm "${imageTag}" /bin/sh -c "cat \\$(which node)"`, { maxBuffer: 100 * 1024 * 1024, encoding: 'buffer' });
return es.readArray([new File({ path: 'node', contents, stat: { mode: parseInt('755', 8) } })]);
} catch (error) {
log.error(`Failed to extract Node.js from Docker image ${imageTag}: ${error.message}`);
throw new Error(`Docker command failed: ${error.message}`);
}
}

const { nodeVersion, internalNodeVersion } = getNodeVersion();
Expand Down Expand Up @@ -231,6 +238,19 @@ function nodejs(platform, arch) {
.pipe(rename('node.exe'));
case 'darwin':
case 'linux':
// Handle alternative architectures that may not have official Node.js builds
if (arch === 'riscv64' && product.nodejsRepository === 'https://nodejs.org') {
// Try unofficial builds site for riscv64
const unofficialUrl = process.env['VSCODE_NODEJS_SITE'] || 'https://unofficial-builds.nodejs.org';
log(`Attempting to download Node.js from ${unofficialUrl} for ${arch}...`);
return fetchUrls(`/download/release/v${nodeVersion}/node-v${nodeVersion}-linux-${arch}.tar.gz`, {
base: unofficialUrl,
checksumSha256
}).pipe(flatmap(stream => stream.pipe(gunzip()).pipe(untar())))
.pipe(filter('**/node'))
.pipe(util.setExecutableBit('**'))
.pipe(rename('node'));
}
return (product.nodejsRepository !== 'https://nodejs.org' ?
fetchGithub(product.nodejsRepository, { version: `${nodeVersion}-${internalNodeVersion}`, name: expectedName, checksumSha256 }) :
fetchUrls(`/dist/v${nodeVersion}/node-v${nodeVersion}-${platform}-${arch}.tar.gz`, { base: 'https://nodejs.org', checksumSha256 })
Expand Down
72 changes: 69 additions & 3 deletions build/gulpfile.vscode.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,10 @@ const vscodeResourceIncludes = [
'out-build/vs/editor/common/languages/highlights/*.scm',

// Tree Sitter injection queries
'out-build/vs/editor/common/languages/injections/*.scm'
'out-build/vs/editor/common/languages/injections/*.scm',

// React components (Cortexide)
'out-build/vs/workbench/contrib/cortexide/browser/react/out/**'
];

const vscodeResources = [
Expand All @@ -122,6 +125,36 @@ const bootstrapEntryPoints = [
'out-build/bootstrap-fork.js'
];

/**
* Task to verify React build files exist after bundling
*/
const verifyReactFilesAfterBundleTask = task.define('verify-react-files-after-bundle', () => {
const fs = require('fs');
const path = require('path');
const reactOutPath = path.join(__dirname, '../out-vscode/vs/workbench/contrib/cortexide/browser/react/out');

if (!fs.existsSync(reactOutPath)) {
// allow-any-unicode-next-line
console.error(`❌ React build output directory does not exist: ${reactOutPath}`);
console.error('React files were not copied during bundling. This will cause a blank screen!');
throw new Error(`React build output directory does not exist: ${reactOutPath}`);
}

const files = fs.readdirSync(reactOutPath);
const jsFiles = files.filter(f => f.endsWith('.js'));

if (jsFiles.length === 0) {
// allow-any-unicode-next-line
console.error(`❌ No React build files found in ${reactOutPath}`);
console.error('React files were not copied during bundling. This will cause a blank screen!');
throw new Error(`No React build files found in ${reactOutPath}. Expected at least one .js file.`);
}

// allow-any-unicode-next-line
console.log(`✅ Verified ${jsFiles.length} React build files exist in out-vscode/ after bundling`);
return Promise.resolve();
});

const bundleVSCodeTask = task.define('bundle-vscode', task.series(
util.rimraf('out-vscode'),
// Optimize: bundles source files automatically based on
Expand All @@ -141,15 +174,48 @@ const bundleVSCodeTask = task.define('bundle-vscode', task.series(
skipTSBoilerplateRemoval: entryPoint => entryPoint === 'vs/code/electron-browser/workbench/workbench'
}
}
)
),
verifyReactFilesAfterBundleTask // Verify React files are present after bundling
));
gulp.task(bundleVSCodeTask);

const sourceMappingURLBase = `https://main.vscode-cdn.net/sourcemaps/${commit}`;

/**
* Task to verify React build files exist after minification
*/
const verifyReactFilesAfterMinifyTask = task.define('verify-react-files-after-minify', () => {
const fs = require('fs');
const path = require('path');
const reactOutPath = path.join(__dirname, '../out-vscode-min/vs/workbench/contrib/cortexide/browser/react/out');

if (!fs.existsSync(reactOutPath)) {
// allow-any-unicode-next-line
console.error(`❌ React build output directory does not exist: ${reactOutPath}`);
console.error('This will cause a blank screen in the packaged app!');
throw new Error(`React build output directory does not exist: ${reactOutPath}`);
}

const files = fs.readdirSync(reactOutPath);
const jsFiles = files.filter(f => f.endsWith('.js'));

if (jsFiles.length === 0) {
// allow-any-unicode-next-line
console.error(`❌ No React build files found in ${reactOutPath}`);
console.error('This will cause a blank screen in the packaged app!');
throw new Error(`No React build files found in ${reactOutPath}. Expected at least one .js file.`);
}

// allow-any-unicode-next-line
console.log(`✅ Verified ${jsFiles.length} React build files exist in out-vscode-min/`);
return Promise.resolve();
});

const minifyVSCodeTask = task.define('minify-vscode', task.series(
bundleVSCodeTask,
util.rimraf('out-vscode-min'),
optimize.minifyTask('out-vscode', `${sourceMappingURLBase}/core`)
optimize.minifyTask('out-vscode', `${sourceMappingURLBase}/core`),
verifyReactFilesAfterMinifyTask // Verify React files are present after minification
));
gulp.task(minifyVSCodeTask);

Expand Down
33 changes: 31 additions & 2 deletions build/gulpfile.vscode.win32.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,21 +75,50 @@ function buildWin32Setup(arch, target) {
const outputPath = setupDir(arch, target);
fs.mkdirSync(outputPath, { recursive: true });

// CRITICAL: Verify executable exists before creating installer.
// Some upstream builds may still emit Code.exe/Void.exe instead of CortexIDE.exe.
// Fall back to whatever executable actually exists so the installer launch step never breaks.
let exeBasename = product.nameShort;
let expectedExePath = path.join(sourcePath, `${exeBasename}.exe`);
if (!fs.existsSync(expectedExePath)) {
const executableCandidates = fs.readdirSync(sourcePath)
.filter(file => file.toLowerCase().endsWith('.exe'))
.filter(file => {
const lower = file.toLowerCase();
return lower !== 'inno_updater.exe' && !lower.includes('tunnel') && !lower.includes('server');
});

if (executableCandidates.length === 0) {
const errorMsg = `ERROR: Executable not found at expected path: ${expectedExePath}\n` +
`and no other *.exe files were located in ${sourcePath}. ` +
`This will cause "CreateProcess failed; code 2" errors during installation.`;
console.error(errorMsg);
return cb(new Error(errorMsg));
}

exeBasename = path.basename(executableCandidates[0], '.exe');
expectedExePath = path.join(sourcePath, `${exeBasename}.exe`);
console.warn(`⚠️ ${product.nameShort}.exe not found. Using detected executable "${exeBasename}.exe" instead.`);
}
console.log(`✓ Executable verified: ${expectedExePath}`);

const originalProductJsonPath = path.join(sourcePath, 'resources/app/product.json');
const productJsonPath = path.join(outputPath, 'product.json');
const productJson = JSON.parse(fs.readFileSync(originalProductJsonPath, 'utf8'));
productJson['target'] = target;
fs.writeFileSync(productJsonPath, JSON.stringify(productJson, undefined, '\t'));

const quality = product.quality || 'dev';
const dirName = product.win32DirName || product.nameShort || exeBasename;

const definitions = {
NameLong: product.nameLong,
NameShort: product.nameShort,
DirName: product.win32DirName,
DirName: dirName,
Version: pkg.version,
RawVersion: pkg.version.replace(/-\w+$/, ''),
NameVersion: product.win32NameVersion + (target === 'user' ? ' (User)' : ''),
ExeBasename: product.nameShort,
ExeBasename: exeBasename,
RegValueName: product.win32RegValueName,
ShellNameShort: product.win32ShellNameShort,
AppMutex: product.win32MutexName,
Expand Down
1 change: 1 addition & 0 deletions build/lib/extensions.js.patched
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
utf8
Loading