mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-17 23:35:54 +01:00
ci: fix universal build for fs-copyfile usage in git extension (#302332)
This commit is contained in:
@@ -175,6 +175,16 @@ function fromLocalEsbuild(extensionPath: string, esbuildConfigFileName: string):
|
||||
const packagedDependencyFileNames = packagedDependencies.flatMap(dependency =>
|
||||
glob.sync(path.join(extensionPath, 'node_modules', dependency, '**'), { nodir: true, dot: true })
|
||||
.map(filePath => path.relative(extensionPath, filePath))
|
||||
.filter(filePath => {
|
||||
// Exclude non-.node files from build directories to avoid timestamp-sensitive
|
||||
// artifacts (e.g. Makefile) that break macOS universal builds due to SHA mismatches.
|
||||
const parts = filePath.split(path.sep);
|
||||
const buildIndex = parts.indexOf('build');
|
||||
if (buildIndex !== -1) {
|
||||
return filePath.endsWith('.node');
|
||||
}
|
||||
return true;
|
||||
})
|
||||
);
|
||||
|
||||
fileNames = Array.from(new Set([...fileNames, ...packagedDependencyFileNames]));
|
||||
|
||||
Reference in New Issue
Block a user