Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: add a OFFLINE var to Makefile #16686

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ COVTESTS ?= test-cov
GTEST_FILTER ?= "*"
GNUMAKEFLAGS += --no-print-directory
GCOV ?= gcov
OFFLINE ?= false

ifdef JOBS
PARALLEL_ARGS = -j $(JOBS)
Expand Down Expand Up @@ -976,17 +977,21 @@ lint-md-clean:
$(RM) -r tools/remark-preset-lint-node/node_modules

lint-md-build:
ifeq ($(OFFLINE),false)
@if [ ! -d tools/remark-cli/node_modules ]; then \
echo "Markdown linter: installing remark-cli into tools/"; \
cd tools/remark-cli && ../../$(NODE) ../../$(NPM) install; fi
@if [ ! -d tools/remark-preset-lint-node/node_modules ]; then \
echo "Markdown linter: installing remark-preset-lint-node into tools/"; \
cd tools/remark-preset-lint-node && ../../$(NODE) ../../$(NPM) install; fi
endif

lint-md: lint-md-build
ifeq ($(OFFLINE),false)
@echo "Running Markdown linter..."
$(NODE) tools/remark-cli/cli.js -q -f \
./*.md doc src lib benchmark tools/doc/ tools/icu/
endif

LINT_JS_TARGETS = benchmark doc lib test tools
LINT_JS_CMD = tools/eslint/bin/eslint.js --cache \
Expand Down