From 4ea0d134ad650b3653990aab51637fe04f4aa1e5 Mon Sep 17 00:00:00 2001 From: Manish Jethani Date: Thu, 5 Aug 2021 00:10:20 +0530 Subject: [PATCH] Move linting out of tools/make-nodejs.sh (#3803) --- Makefile | 7 ++++++- tools/make-nodejs.sh | 5 ----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index c86298b44..387187b01 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -.PHONY: all clean install chromium firefox nodejs install-nodejs-link install-nodejs uninstall-nodejs +.PHONY: all clean lint install chromium firefox nodejs install-nodejs-link install-nodejs uninstall-nodejs sources := $(wildcard src/* src/*/* src/*/*/* src/*/*/*/*) platform := $(wildcard platform/* platform/*/*) @@ -44,6 +44,11 @@ install-nodejs: dist/build/uBlock0.nodejs.tgz uninstall-nodejs: npm uninstall '@gorhill/ubo-core' --no-save +lint: nodejs + eslint -c platform/nodejs/eslintrc.json \ + dist/build/uBlock0.nodejs/js \ + dist/build/uBlock0.nodejs/*.js + # Update submodules. update-submodules: tools/update-submodules.sh diff --git a/tools/make-nodejs.sh b/tools/make-nodejs.sh index 654ebb310..e9ed6bac7 100755 --- a/tools/make-nodejs.sh +++ b/tools/make-nodejs.sh @@ -56,11 +56,6 @@ cp platform/nodejs/*.js $DES/ cp platform/nodejs/*.json $DES/ cp LICENSE.txt $DES/ -# Ignore eslint when building with GitHub Actions -if [ -z "$GITHUB_REF" ]; then - eslint -c platform/nodejs/eslintrc.json $DES/js $DES/*.js -fi - if [ "$1" = all ]; then echo "*** uBlock0.nodejs: Creating plain package..." pushd $(dirname $DES/) > /dev/null