@@ -169,6 +169,9 @@ if "%target%"=="Clean" echo deleting %~dp0deps\icu
169169if " %target% " == " Clean" rmdir /S /Q %~dp0 deps\icu
170170:no-depsicu
171171
172+ call tools\msvs\find_python.cmd
173+ if errorlevel 1 echo Could not find python2 & goto :exit
174+
172175call :getnodeversion || exit /b 1
173176
174177if defined TAG set configure_flags = %configure_flags% --tag=%TAG%
@@ -265,7 +268,8 @@ goto run
265268if defined noprojgen goto msbuild
266269
267270@ rem Generate the VS project.
268- call :run-python configure %configure_flags%
271+ echo configure %configure_flags%
272+ python configure %configure_flags%
269273if errorlevel 1 goto create-msvs-files-failed
270274if not exist node.sln goto create-msvs-files-failed
271275echo Project files generated.
@@ -457,7 +461,7 @@ if defined test_node_inspect goto node-test-inspect
457461goto node-tests
458462
459463:node-check-deopts
460- call : run- python tools\test.py --mode=release --check-deopts parallel sequential -J
464+ python tools\test.py --mode=release --check-deopts parallel sequential -J
461465if defined test_node_inspect goto node-test-inspect
462466goto node-tests
463467
@@ -481,7 +485,8 @@ if defined no_cctest echo Skipping cctest because no-cctest was specified && got
481485echo running 'cctest %cctest_args% '
482486" %config% \cctest" %cctest_args%
483487:run-test-py
484- call :run-python tools\test.py %test_args%
488+ echo running 'python tools\test.py %test_args% '
489+ python tools\test.py %test_args%
485490goto test-v8
486491
487492:test-v8
@@ -493,7 +498,7 @@ goto lint-cpp
493498:lint-cpp
494499if not defined lint_cpp goto lint-js
495500call :run-lint-cpp src\*.c src\*.cc src\*.h test\addons\*.cc test\addons\*.h test\addons-napi\*.cc test\addons-napi\*.h test\cctest\*.cc test\cctest\*.h test\gc\binding.cc tools\icu\*.cc tools\icu\*.h
496- call : run- python tools/check-imports.py
501+ python tools/check-imports.py
497502goto lint-js
498503
499504:run-lint-cpp
@@ -509,7 +514,7 @@ for /f "tokens=*" %%G in ('dir /b /s /a %*') do (
509514( endlocal
510515 set cppfilelist = %localcppfilelist%
511516)
512- call : run- python tools/cpplint.py %cppfilelist% > nul
517+ python tools/cpplint.py %cppfilelist% > nul
513518goto exit
514519
515520:add-to-list
@@ -571,14 +576,6 @@ echo vcbuild.bat lint : runs the C++ and JavaScript linter
571576echo vcbuild.bat no-cctest : skip building cctest.exe
572577goto exit
573578
574- :run-python
575- call tools\msvs\find_python.cmd
576- if errorlevel 1 echo Could not find python2 & goto :exit
577- set cmd1 = " %VCBUILD_PYTHON_LOCATION% " %*
578- echo %cmd1%
579- %cmd1%
580- exit /b %ERRORLEVEL%
581-
582579:exit
583580goto :EOF
584581
@@ -591,9 +588,8 @@ rem ***************
591588set NODE_VERSION =
592589set TAG =
593590set FULLVERSION =
594- :: Call as subroutine for validation of python
595- call :run-python tools\getnodeversion.py > nul
596- for /F " tokens=*" %%i in ('" %VCBUILD_PYTHON_LOCATION% " tools\getnodeversion.py') do set NODE_VERSION = %%i
591+
592+ for /F " usebackq tokens=*" %%i in (`python " %~dp0 tools\getnodeversion.py" `) do set NODE_VERSION = %%i
597593if not defined NODE_VERSION (
598594 echo Cannot determine current version of Node.js
599595 exit /b 1
0 commit comments