Skip to content

Commit 62dd160

Browse files
committed
fix: Fix phantom.min.js path check in create-release.js
- Use path.join for checking minified file existence - Ensures script works correctly from scripts/ directory
1 parent 3fd3f60 commit 62dd160

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

scripts/create-release.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,10 @@ const RELEASE_FILES = [
3838
console.log('📦 Creating release package...\n');
3939

4040
// Ensure minified file exists
41-
if (!fs.existsSync('phantom.min.js')) {
41+
const minifiedPath = path.join(__dirname, '..', 'phantom.min.js');
42+
if (!fs.existsSync(minifiedPath)) {
4243
console.log('⚠️ phantom.min.js not found. Generating...');
43-
execSync('npm run minify', { stdio: 'inherit' });
44+
execSync('npm run minify', { stdio: 'inherit', cwd: __dirname });
4445
}
4546

4647
// Create release directory

0 commit comments

Comments
 (0)