summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorDaijiro Wachi <daijiro.wachi@gmail.com>2017-04-30 21:07:38 +0200
committerDaijiro Wachi <daijiro.wachi@gmail.com>2017-10-25 21:13:22 +0200
commitf1329543d6d2f092d4dbd516773af07383955543 (patch)
treeec65e81af3782be6825e600a1b05a2171d12e507 /Makefile
parent92dff06122fb87737f386e86d9e26ba205a9e04a (diff)
downloadnode-new-f1329543d6d2f092d4dbd516773af07383955543.tar.gz
tools: add lint-md command in Makefile
PR-URL: https://github.com/nodejs/node/pull/12756 Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile11
1 files changed, 9 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 1017452f08..52fa2ee6d6 100644
--- a/Makefile
+++ b/Makefile
@@ -804,7 +804,7 @@ $(TARBALL): release-only $(NODE_EXE) doc
$(RM) -r $(TARNAME)/deps/openssl/openssl/{doc,demos,test}
$(RM) -r $(TARNAME)/deps/zlib/contrib # too big, unused
$(RM) -r $(TARNAME)/.{editorconfig,git*,mailmap}
- $(RM) -r $(TARNAME)/tools/{eslint,eslint-rules,osx-pkg.pmdoc,pkgsrc}
+ $(RM) -r $(TARNAME)/tools/{eslint,eslint-rules,osx-pkg.pmdoc,pkgsrc,remark-cli,remark-preset-lint-node}
$(RM) -r $(TARNAME)/tools/{osx-*,license-builder.sh,cpplint.py}
$(RM) -r $(TARNAME)/test*.tap
find $(TARNAME)/ -name ".eslint*" -maxdepth 2 | xargs $(RM)
@@ -945,6 +945,11 @@ bench: bench-net bench-http bench-fs bench-tls
bench-ci: bench
+lint-md:
+ @echo "Running Markdown linter..."
+ $(NODE) tools/remark-cli/cli.js -q -f \
+ ./*.md doc src lib benchmark tools/doc/ tools/icu/
+
LINT_JS_TARGETS = benchmark doc lib test tools
lint-js:
@@ -1002,9 +1007,10 @@ lint:
@EXIT_STATUS=0 ; \
$(MAKE) lint-js || EXIT_STATUS=$$? ; \
$(MAKE) lint-cpp || EXIT_STATUS=$$? ; \
+ $(MAKE) lint-md || EXIT_STATUS=$$? ; \
exit $$EXIT_STATUS
CONFLICT_RE=^>>>>>>> [0-9A-Fa-f]+|^<<<<<<< [A-Za-z]+
-lint-ci: lint-js-ci lint-cpp
+lint-ci: lint-js-ci lint-cpp lint-md
@if ! ( grep -IEqrs "$(CONFLICT_RE)" benchmark deps doc lib src test tools ) \
&& ! ( find . -maxdepth 1 -type f | xargs grep -IEqs "$(CONFLICT_RE)" ); then \
exit 0 ; \
@@ -1067,6 +1073,7 @@ endif
lint-js \
lint-js-ci \
list-gtests \
+ lint-md \
pkg \
release-only \
run-ci \