@orxataguy/tyr 1.0.11-beta.0 → 1.0.11-beta.1
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/bin/tyr.js +3 -2
- package/package.json +1 -1
package/bin/tyr.js
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* NODE_NO_WARNINGS suppresses the deprecation notice.
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
|
-
import { fileURLToPath } from 'url';
|
|
15
|
+
import { fileURLToPath, pathToFileURL } from 'url';
|
|
16
16
|
import { dirname, join } from 'path';
|
|
17
17
|
import { spawn } from 'child_process';
|
|
18
18
|
|
|
@@ -20,12 +20,13 @@ const __filename = fileURLToPath(import.meta.url);
|
|
|
20
20
|
const __dirname = dirname(__filename);
|
|
21
21
|
|
|
22
22
|
const loaderPath = join(__dirname, 'loader.mjs');
|
|
23
|
+
const loaderUrl = pathToFileURL(loaderPath).href; // file:// URL — required on Windows
|
|
23
24
|
const entry = join(__dirname, 'tyr.ts');
|
|
24
25
|
|
|
25
26
|
const child = spawn(
|
|
26
27
|
process.execPath,
|
|
27
28
|
[
|
|
28
|
-
'--loader',
|
|
29
|
+
'--loader', loaderUrl,
|
|
29
30
|
'--no-warnings', // suppress ExperimentalWarning for --loader in Node 22
|
|
30
31
|
entry,
|
|
31
32
|
...process.argv.slice(2),
|