diff --git a/scripts/downloadBackend.ts b/scripts/downloadBackend.ts index 34bb2421..7550b5ee 100755 --- a/scripts/downloadBackend.ts +++ b/scripts/downloadBackend.ts @@ -6,21 +6,16 @@ import * as dotenv from 'dotenv' import * as upath from 'upath' import { parse as parseUrl } from 'url' -const dirname = __dirname?.startsWith('D:') - ? upath.normalize(__dirname).replace('D:', '/d') - : __dirname - -// upath.normalize(__dirname) dotenv.config({ path: [ - upath.join(dirname, '..', '.env'), + path.join(__dirname, '..', '.env'), ] }) const target = process.argv[2]; const cdnPath = process.env.RI_CDN_PATH -const backendPath = upath.join(dirname, '..', 'dist', 'redis-backend') -const tutorialsPath = upath.join(backendPath, 'dist-minified', 'defaults', 'tutorials') +const backendPath = path.join(__dirname, '..', 'dist', 'redis-backend') +const tutorialsPath = path.join(backendPath, 'dist-minified', 'defaults', 'tutorials') const downloadBackend = async () => { if (fs.existsSync(backendPath)) {