Skip to content

Commit ff3946c

Browse files
Rename bsb_exe variable to rescript_exe where it points to rescript.exe (rescript-lang#5190)
Hopefully clears up some confusion.
1 parent b1919a9 commit ff3946c

File tree

4 files changed

+15
-15
lines changed

4 files changed

+15
-15
lines changed

rescript

+6-6
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ var bin_path = path.join(
2727
/**
2828
* @type{string}
2929
*/
30-
var bsb_exe = path.join(bin_path, "rescript.exe");
30+
var rescript_exe = path.join(bin_path, "rescript.exe");
3131

3232
var LAST_BUILD_START = 0;
3333
var LAST_FIRED_EVENT = 0;
@@ -232,22 +232,22 @@ if (
232232
case "format":
233233
require("./scripts/rescript_format.js").main(
234234
process.argv.slice(3),
235-
bsb_exe,
235+
rescript_exe,
236236
bsc_exe
237237
);
238238
break;
239239
case "dump":
240240
require("./scripts/rescript_dump.js").main(
241241
process.argv.slice(3),
242-
bsb_exe,
242+
rescript_exe,
243243
bsc_exe
244244
);
245245
break;
246246
case "convert":
247247
// Todo
248248
require("./scripts/rescript_convert.js").main(
249249
process.argv.slice(3),
250-
bsb_exe,
250+
rescript_exe,
251251
bsc_exe
252252
);
253253
break;
@@ -295,7 +295,7 @@ if (
295295
var p;
296296
if (acquireBuild) {
297297
try {
298-
p = child_process.spawn(bsb_exe, delegate_args, { stdio: "inherit" });
298+
p = child_process.spawn(rescript_exe, delegate_args, { stdio: "inherit" });
299299
LAST_BUILD_START = +Date.now();
300300
} catch (e) {
301301
if (e.code === "ENOENT") {
@@ -513,7 +513,7 @@ if (
513513
if (acquireBuild()) {
514514
logStart();
515515
child_process
516-
.spawn(bsb_exe, [], {
516+
.spawn(rescript_exe, [], {
517517
stdio: ["inherit", "inherit", "pipe"],
518518
})
519519
// @ts-ignore

scripts/rescript_convert.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,10 @@ function handleOneFile(file, bsc_exe) {
6464
}
6565
/**
6666
* @param {string[]} argv
67-
* @param {string} bsb_exe
67+
* @param {string} rescript_exe
6868
* @param {string} bsc_exe
6969
*/
70-
function main(argv, bsb_exe, bsc_exe) {
70+
function main(argv, rescript_exe, bsc_exe) {
7171
try {
7272
/**
7373
* @type {string[]}
@@ -86,7 +86,7 @@ function main(argv, bsb_exe, bsc_exe) {
8686
}
8787
// -all
8888
// TODO: check the rest arguments
89-
var output = child_process.spawnSync(bsb_exe, ["info", "-list-files"], {
89+
var output = child_process.spawnSync(rescript_exe, ["info", "-list-files"], {
9090
encoding: "utf-8",
9191
});
9292
if (output.status !== 0) {

scripts/rescript_dump.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@ var specs = [];
99

1010
/**
1111
* @param {string[]} argv
12-
* @param {string} bsb_exe
12+
* @param {string} rescript_exe
1313
* @param {string} bsc_exe
1414
*/
15-
function main(argv, bsb_exe, bsc_exe) {
15+
function main(argv, rescript_exe, bsc_exe) {
1616
var target;
1717
arg.parse_exn(dump_usage, argv, specs, (xs) => {
1818
if (xs.length !== 1) {
@@ -29,7 +29,7 @@ function main(argv, bsb_exe, bsc_exe) {
2929

3030

3131
var output = child_process.spawnSync(
32-
bsb_exe,
32+
rescript_exe,
3333
["build", "--", target],
3434
{
3535
encoding: "utf-8",

scripts/rescript_format.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,10 @@ async function readStdin() {
5757

5858
/**
5959
* @param {string[]} argv
60-
* @param {string} bsb_exe
60+
* @param {string} rescript_exe
6161
* @param {string} bsc_exe
6262
*/
63-
function main(argv, bsb_exe, bsc_exe) {
63+
function main(argv, rescript_exe, bsc_exe) {
6464
var isSupportedFile = hasExtension(formattedFileExtensions);
6565
var isSupportedStd = hasExtension(formattedStdExtensions);
6666

@@ -82,7 +82,7 @@ function main(argv, bsb_exe, bsc_exe) {
8282
}
8383
// -all
8484
// TODO: check the rest arguments
85-
var output = child_process.spawnSync(bsb_exe, ["info", "-list-files"], {
85+
var output = child_process.spawnSync(rescript_exe, ["info", "-list-files"], {
8686
encoding: "utf-8",
8787
});
8888
if (output.status !== 0) {

0 commit comments

Comments
 (0)