electrobun 0.0.19-beta.17 → 0.0.19-beta.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/cli/index.ts +17 -3
package/package.json
CHANGED
package/src/cli/index.ts
CHANGED
|
@@ -92,12 +92,26 @@ const PATHS = {
|
|
|
92
92
|
};
|
|
93
93
|
|
|
94
94
|
async function ensureCoreDependencies() {
|
|
95
|
-
// Check if core dependencies
|
|
96
|
-
|
|
95
|
+
// Check if all core dependencies exist
|
|
96
|
+
const requiredFiles = [
|
|
97
|
+
PATHS.BUN_BINARY,
|
|
98
|
+
PATHS.LAUNCHER_RELEASE,
|
|
99
|
+
PATHS.MAIN_JS,
|
|
100
|
+
// Platform-specific native wrapper
|
|
101
|
+
OS === 'macos' ? PATHS.NATIVE_WRAPPER_MACOS :
|
|
102
|
+
OS === 'win' ? PATHS.NATIVE_WRAPPER_WIN :
|
|
103
|
+
PATHS.NATIVE_WRAPPER_LINUX
|
|
104
|
+
];
|
|
105
|
+
|
|
106
|
+
const allFilesExist = requiredFiles.every(file => existsSync(file));
|
|
107
|
+
if (allFilesExist) {
|
|
97
108
|
return;
|
|
98
109
|
}
|
|
99
110
|
|
|
100
|
-
|
|
111
|
+
// Show which files are missing
|
|
112
|
+
const missingFiles = requiredFiles.filter(file => !existsSync(file));
|
|
113
|
+
console.log('Core dependencies not found. Missing files:', missingFiles.map(f => f.replace(ELECTROBUN_DEP_PATH, '.')).join(', '));
|
|
114
|
+
console.log('Downloading core binaries...');
|
|
101
115
|
|
|
102
116
|
// Get the current Electrobun version from package.json
|
|
103
117
|
const packageJsonPath = join(ELECTROBUN_DEP_PATH, 'package.json');
|