Spaces:
Runtime error
Runtime error
Download build.js from sardarbipul/work-Update: direct link, hf CLI and curl.
- Browser
- Download file 583 Bytes
-
https://huggingface.co/spaces/sardarbipul/work-Update/resolve/main/build.js
- Command line
-
hf download hf://spaces/sardarbipul/work-Update/build.js
-
curl -L -o build.js https://huggingface.co/spaces/sardarbipul/work-Update/resolve/main/build.js
583 Bytes
| const { execSync } = require('child_process'); | |
| const fs = require('fs'); | |
| const path = require('path'); | |
| console.log('Compiling TypeScript...'); | |
| execSync('npx tsc', { stdio: 'inherit' }); | |
| const sourcePath = path.join(__dirname, 'ca.pem'); | |
| const destPath = path.join(__dirname, 'dist', 'ca.pem'); | |
| if (fs.existsSync(sourcePath)) { | |
| fs.copyFileSync(sourcePath, destPath); | |
| console.log('ca.pem copied to dist folder successfully.'); | |
| } else { | |
| console.error('ca.pem not found in project root. Please ensure it exists.'); | |
| process.exit(1); | |
| } | |
| console.log('Build completed successfully.'); |