File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -331,20 +331,20 @@ function getBscArgs(
331331 }
332332 }
333333
334- const rewatchArguments = semver . satisfies ( project . rescriptVersion , ">12.0.0-alpha.14 " , { includePrerelease : true } ) ? [
334+ const rewatchArguments = semver . satisfies ( project . rescriptVersion , ">= 12.0.0-beta.2 " , { includePrerelease : true } ) ? [
335335 "compiler-args" ,
336- "--rescript-version" ,
337- project . rescriptVersion ,
338336 entry . file . sourceFilePath ,
339337 ] : [
340338 "--rescript-version" ,
341339 project . rescriptVersion ,
342340 "--compiler-args" ,
343341 entry . file . sourceFilePath ,
344342 ] ;
343+ const bscExe = await utils . findBscExeBinary ( entry . project . workspaceRootPath ) ;
344+ const env = bscExe != null ? { RESCRIPT_BSC_EXE : bscExe } : undefined ;
345345 const compilerArgs = JSON . parse (
346346 cp
347- . execFileSync ( rewatchPath , rewatchArguments )
347+ . execFileSync ( rewatchPath , rewatchArguments , { env } )
348348 . toString ( )
349349 . trim ( )
350350 ) as RewatchCompilerArgs ;
You can’t perform that action at this time.
0 commit comments