File tree Expand file tree Collapse file tree 1 file changed +16
-8
lines changed
tools/make/lib/lint/javascript Expand file tree Collapse file tree 1 file changed +16
-8
lines changed Original file line number Diff line number Diff line change @@ -253,18 +253,26 @@ endif
253253eslint-files : $(NODE_MODULES )
254254ifeq ($(FAIL_FAST ) , true)
255255 $(QUIET) for file in $(FILES); do \
256- echo ''; \
257- echo "Linting file: $$file"; \
258- $(ESLINT) $(eslint_flags) --config $(ESLINT_CONF) $$file || exit 1; \
256+ if [ -f "$$file" ]; then \
257+ echo ''; \
258+ echo "Linting file: $$file"; \
259+ $(ESLINT) $(eslint_flags) --config $(ESLINT_CONF) $$file || exit 1; \
260+ else \
261+ echo "Skipping missing file: $$file"; \
262+ fi; \
259263 done
260264else
261265 $(QUIET) status=0; \
262266 for file in $(FILES); do \
263- echo ''; \
264- echo "Linting file: $$file"; \
265- if ! $(ESLINT) $(eslint_flags) --config $(ESLINT_CONF) $$file; then \
266- echo 'Linting failed.'; \
267- status=1; \
267+ if [ -f "$$file" ]; then \
268+ echo ''; \
269+ echo "Linting file: $$file"; \
270+ if ! $(ESLINT) $(eslint_flags) --config $(ESLINT_CONF) $$file; then \
271+ echo 'Linting failed.'; \
272+ status=1; \
273+ fi; \
274+ else \
275+ echo "Skipping missing file: $$file"; \
268276 fi; \
269277 done; \
270278 exit $$status;
You can’t perform that action at this time.
0 commit comments