@@ -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 buildnodeweak =
32
32
set noetw =
33
33
set noetw_msi_arg =
@@ -58,7 +58,7 @@ if /i "%1"=="nosnapshot" set nosnapshot=1&goto arg-ok
58
58
if /i " %1 " == " noetw" set noetw = 1& goto arg-ok
59
59
if /i " %1 " == " noperfctr" set noperfctr = 1& goto arg-ok
60
60
if /i " %1 " == " licensertf" set licensertf = 1& goto arg-ok
61
- if /i " %1 " == " test" set test_args = %test_args% doctool known_issues message parallel sequential addons -J& set cpplint =1& set jslint =1& set build_addons=1& goto arg-ok
61
+ if /i " %1 " == " test" set test_args = %test_args% doctool known_issues message parallel sequential addons -J& set lint_cpp =1& set lint_js =1& set build_addons=1& goto arg-ok
62
62
if /i " %1 " == " test-ci" set test_args = %test_args% %test_ci_args% -p tap --logfile test.tap doctool inspector known_issues message sequential parallel addons& set cctest_args=%cctest_args% --gtest_output=tap:cctest.tap& set build_addons=1& goto arg-ok
63
63
if /i " %1 " == " test-addons" set test_args = %test_args% addons& set build_addons=1& goto arg-ok
64
64
if /i " %1 " == " test-simple" set test_args = %test_args% sequential parallel -J& goto arg-ok
@@ -68,13 +68,16 @@ if /i "%1"=="test-inspector" set test_args=%test_args% inspector&goto arg-ok
68
68
if /i " %1 " == " test-tick-processor" set test_args = %test_args% tick-processor& goto arg-ok
69
69
if /i " %1 " == " test-internet" set test_args = %test_args% internet& goto arg-ok
70
70
if /i " %1 " == " test-pummel" set test_args = %test_args% pummel& goto arg-ok
71
- if /i " %1 " == " test-all" set test_args = %test_args% sequential parallel message gc inspector internet pummel& set buildnodeweak=1& set cpplint =1& set jslint =1& goto arg-ok
71
+ if /i " %1 " == " test-all" set test_args = %test_args% sequential parallel message gc inspector internet pummel& set buildnodeweak=1& set lint_cpp =1& set lint_js =1& goto arg-ok
72
72
if /i " %1 " == " test-known-issues" set test_args = %test_args% known_issues& goto arg-ok
73
- if /i " %1 " == " jslint" set jslint = 1& goto arg-ok
74
- if /i " %1 " == " jslint-ci" set jslint_ci = 1& goto arg-ok
75
- if /i " %1 " == " cpplint" set cpplint = 1& goto arg-ok
76
- if /i " %1 " == " lint" set cpplint = 1& set jslint=1& goto arg-ok
77
- if /i " %1 " == " lint-ci" set cpplint = 1& set jslint_ci=1& goto arg-ok
73
+ if /i " %1 " == " lint-js" set lint_js = 1& goto arg-ok
74
+ if /i " %1 " == " jslint" set lint_js = 1& goto arg-ok
75
+ if /i " %1 " == " lint-js-ci" set lint_js_ci = 1& goto arg-ok
76
+ if /i " %1 " == " jslint-ci" set lint_js_ci = 1& goto arg-ok
77
+ if /i " %1 " == " lint-cpp" set lint_cpp = 1& goto arg-ok
78
+ if /i " %1 " == " cpplint" set lint_cpp = 1& goto arg-ok
79
+ if /i " %1 " == " lint" set lint_cpp = 1& set lint_js=1& goto arg-ok
80
+ if /i " %1 " == " lint-ci" set lint_cpp = 1& set lint_js_ci=1& goto arg-ok
78
81
if /i " %1 " == " package" set package = 1& goto arg-ok
79
82
if /i " %1 " == " msi" set msi = 1& set licensertf=1& set download_arg=" --download=all" & set i18n_arg=small-icu& goto arg-ok
80
83
if /i " %1 " == " build-release" set build_release = 1& goto arg-ok
@@ -340,23 +343,23 @@ endlocal
340
343
goto run-tests
341
344
342
345
:run-tests
343
- if " %test_args% " == " " goto cpplint
346
+ if " %test_args% " == " " goto lint-cpp
344
347
if " %config% " == " Debug" set test_args = --mode=debug %test_args%
345
348
if " %config% " == " Release" set test_args = --mode=release %test_args%
346
349
echo running 'cctest %cctest_args% '
347
350
" %config% \cctest" %cctest_args%
348
351
call :run-python tools\test.py %test_args%
349
- goto cpplint
352
+ goto lint-cpp
350
353
351
- :cpplint
352
- if not defined cpplint goto jslint
353
- call :run-cpplint src\*.c src\*.cc src\*.h test\addons\*.cc test\addons\*.h test\cctest\*.cc test\cctest\*.h tools\icu\*.cc tools\icu\*.h
354
+ :lint-cpp
355
+ if not defined lint_cpp goto lint-js
356
+ call :run-lint-cpp src\*.c src\*.cc src\*.h test\addons\*.cc test\addons\*.h test\cctest\*.cc test\cctest\*.h tools\icu\*.cc tools\icu\*.h
354
357
call :run-python tools/check-imports.py
355
- goto jslint
358
+ goto lint-js
356
359
357
- :run-cpplint
360
+ :run-lint-cpp
358
361
if " %* " == " " goto exit
359
- echo running cpplint '%* '
362
+ echo running lint-cpp '%* '
360
363
set cppfilelist =
361
364
setlocal enabledelayedexpansion
362
365
for /f " tokens=*" %%G in ('dir /b /s /a %* ') do (
@@ -393,17 +396,17 @@ if %errorlevel% equ 0 goto exit
393
396
set " localcppfilelist = %localcppfilelist% %1 "
394
397
goto exit
395
398
396
- :jslint
397
- if defined jslint_ci goto jslint -ci
398
- if not defined jslint goto exit
399
+ :lint-js
400
+ if defined lint_js_ci goto lint-js -ci
401
+ if not defined lint_js goto exit
399
402
if not exist tools\eslint goto no-lint
400
- echo running jslint
403
+ echo running lint-js
401
404
%config% \node tools\eslint\bin\eslint.js --cache --rule " linebreak-style: 0" --rulesdir=tools\eslint-rules --ext=.js,.md benchmark doc lib test tools
402
405
goto exit
403
406
404
- :jslint -ci
405
- echo running jslint -ci
406
- %config% \node tools\jslint .js -J -f tap -o test-eslint.tap benchmark doc lib test tools
407
+ :lint-js -ci
408
+ echo running lint-js -ci
409
+ %config% \node tools\lint-js .js -J -f tap -o test-eslint.tap benchmark doc lib test tools
407
410
goto exit
408
411
409
412
:no-lint
0 commit comments