@@ -26,8 +26,8 @@ set package=
26
26
set msi =
27
27
set upload =
28
28
set licensertf =
29
- set jslint =
30
- set cpplint =
29
+ set lint_js =
30
+ set lint_cpp =
31
31
set build_testgc_addon =
32
32
set noetw =
33
33
set noetw_msi_arg =
@@ -72,7 +72,7 @@ if /i "%1"=="nosnapshot" set nosnapshot=1&goto arg-ok
72
72
if /i " %1 " == " noetw" set noetw = 1& goto arg-ok
73
73
if /i " %1 " == " noperfctr" set noperfctr = 1& goto arg-ok
74
74
if /i " %1 " == " licensertf" set licensertf = 1& goto arg-ok
75
- if /i " %1 " == " test" set test_args = %test_args% -J %common_test_suites% & set cpplint =1& set jslint =1& goto arg-ok
75
+ if /i " %1 " == " test" set test_args = %test_args% -J %common_test_suites% & set lint_cpp =1& set lint_js =1& goto arg-ok
76
76
if /i " %1 " == " test-ci" set test_args = %test_args% %test_ci_args% -p tap --logfile test.tap %common_test_suites% & set cctest_args=%cctest_args% --gtest_output=tap:cctest.tap& goto arg-ok
77
77
if /i " %1 " == " test-addons" set test_args = %test_args% addons& set build_addons=1& goto arg-ok
78
78
if /i " %1 " == " test-addons-napi" set test_args = %test_args% addons-napi& set build_addons_napi=1& goto arg-ok
@@ -85,17 +85,19 @@ if /i "%1"=="test-internet" set test_args=%test_args% internet&goto arg-ok
85
85
if /i " %1 " == " test-pummel" set test_args = %test_args% pummel& goto arg-ok
86
86
if /i " %1 " == " test-known-issues" set test_args = %test_args% known_issues& goto arg-ok
87
87
if /i " %1 " == " test-async-hooks" set test_args = %test_args% async-hooks& goto arg-ok
88
- if /i " %1 " == " test-all" set test_args = %test_args% gc internet pummel %common_test_suites% & set build_testgc_addon=1& set cpplint =1& set jslint =1& goto arg-ok
88
+ if /i " %1 " == " test-all" set test_args = %test_args% gc internet pummel %common_test_suites% & set build_testgc_addon=1& set lint_cpp =1& set lint_js =1& goto arg-ok
89
89
if /i " %1 " == " test-node-inspect" set test_node_inspect = 1& goto arg-ok
90
90
if /i " %1 " == " test-check-deopts" set test_check_deopts = 1& goto arg-ok
91
91
if /i " %1 " == " test-v8" set test_v8 = 1& set custom_v8_test=1& goto arg-ok
92
92
if /i " %1 " == " test-v8-intl" set test_v8_intl = 1& set custom_v8_test=1& goto arg-ok
93
93
if /i " %1 " == " test-v8-benchmarks" set test_v8_benchmarks = 1& set custom_v8_test=1& goto arg-ok
94
94
if /i " %1 " == " test-v8-all" set test_v8 = 1& set test_v8_intl=1& set test_v8_benchmarks=1& set custom_v8_test=1& goto arg-ok
95
- if /i " %1 " == " jslint" set jslint = 1& goto arg-ok
96
- if /i " %1 " == " jslint-ci" set jslint_ci = 1& goto arg-ok
97
- if /i " %1 " == " lint" set cpplint = 1& set jslint=1& goto arg-ok
98
- if /i " %1 " == " lint-ci" set cpplint = 1& set jslint_ci=1& goto arg-ok
95
+ if /i " %1 " == " lint-js" set lint_js = 1& goto arg-ok
96
+ if /i " %1 " == " jslint" set lint_js = 1& echo Please use lint-js instead of jslint& goto arg-ok
97
+ if /i " %1 " == " lint-js-ci" set lint_js_ci = 1& goto arg-ok
98
+ if /i " %1 " == " jslint-ci" set lint_js_ci = 1& echo Please use lint-js-ci instead of jslint-ci& goto arg-ok
99
+ if /i " %1 " == " lint" set lint_cpp = 1& set lint_js=1& goto arg-ok
100
+ if /i " %1 " == " lint-ci" set lint_cpp = 1& set lint_js_ci=1& goto arg-ok
99
101
if /i " %1 " == " package" set package = 1& goto arg-ok
100
102
if /i " %1 " == " msi" set msi = 1& set licensertf=1& set download_arg=" --download=all" & set i18n_arg=small-icu& goto arg-ok
101
103
if /i " %1 " == " build-release" set build_release = 1& set sign=1& goto arg-ok
@@ -457,20 +459,20 @@ if defined enable_static goto test-v8
457
459
call :run-python tools\test.py %test_args%
458
460
459
461
:test-v8
460
- if not defined custom_v8_test goto cpplint
462
+ if not defined custom_v8_test goto lint-cpp
461
463
call tools/test-v8.bat
462
464
if errorlevel 1 goto exit
463
- goto cpplint
465
+ goto lint-cpp
464
466
465
- :cpplint
466
- if not defined cpplint goto jslint
467
- call :run-cpplint src\*.c src\*.cc src\*.h test\addons\*.cc test\addons\*.h test\cctest\*.cc test\cctest\*.h test\gc\binding.cc tools\icu\*.cc tools\icu\*.h
467
+ :lint-cpp
468
+ if not defined lint_cpp goto lint-js
469
+ call :run-lint-cpp src\*.c src\*.cc src\*.h test\addons\*.cc test\addons\*.h test\cctest\*.cc test\cctest\*.h test\gc\binding.cc tools\icu\*.cc tools\icu\*.h
468
470
call :run-python tools/check-imports.py
469
- goto jslint
471
+ goto lint-js
470
472
471
- :run-cpplint
473
+ :run-lint-cpp
472
474
if " %* " == " " goto exit
473
- echo running cpplint '%* '
475
+ echo running lint-cpp '%* '
474
476
set cppfilelist =
475
477
setlocal enabledelayedexpansion
476
478
for /f " tokens=*" %%G in ('dir /b /s /a %* ') do (
@@ -501,18 +503,18 @@ if %errorlevel% equ 0 goto exit
501
503
set " localcppfilelist = %localcppfilelist% %1 "
502
504
goto exit
503
505
504
- :jslint
506
+ :lint-js
505
507
if defined enable_static goto exit
506
- if defined jslint_ci goto jslint -ci
507
- if not defined jslint goto exit
508
+ if defined lint_js_ci goto lint-js -ci
509
+ if not defined lint_js goto exit
508
510
if not exist tools\eslint goto no-lint
509
- echo running jslint
511
+ echo running lint-js
510
512
%config% \node tools\eslint\bin\eslint.js --cache --rule " linebreak-style: 0" --rulesdir=tools\eslint-rules --ext=.js,.md benchmark doc lib test tools
511
513
goto exit
512
514
513
- :jslint -ci
514
- echo running jslint -ci
515
- %config% \node tools\jslint .js -J -f tap -o test-eslint.tap benchmark doc lib test tools
515
+ :lint-js -ci
516
+ echo running lint-js -ci
517
+ %config% \node tools\lint-js .js -J -f tap -o test-eslint.tap benchmark doc lib test tools
516
518
goto exit
517
519
518
520
:no-lint
0 commit comments