From 6dfc16f0fc717d6249ecdd36261abc621d0f56e6 Mon Sep 17 00:00:00 2001 From: Whymarrh Whitby Date: Thu, 22 Aug 2019 09:21:16 -0230 Subject: [PATCH] Add lint:changed script entry to lint only changed files (#7055) --- package.json | 2 ++ 1 file changed, 2 insertions(+) diff --git a/package.json b/package.json index 44505d0f3..a538ab700 100644 --- a/package.json +++ b/package.json @@ -34,6 +34,8 @@ "sentry:publish": "node ./development/sentry-publish.js", "lint": "eslint . --ext js,json", "lint:fix": "eslint . --ext js,json --fix", + "lint:changed": "{ git ls-files --others --exclude-standard ; git diff-index --name-only --diff-filter=d HEAD ; } | grep --regexp='[.]js$' --regexp='[.]json$' | tr '\\n' '\\0' | xargs -0 eslint", + "lint:changed:fix": "{ git ls-files --others --exclude-standard ; git diff-index --name-only --diff-filter=d HEAD ; } | grep --regexp='[.]js$' --regexp='[.]json$' | tr '\\n' '\\0' | xargs -0 eslint --fix", "mozilla-lint": "addons-linter dist/firefox", "watch": "cross-env METAMASK_ENV=test mocha --watch --require test/setup.js --reporter min --recursive \"test/unit/**/*.js\" \"ui/app/**/*.test.js\"", "devtools:react": "react-devtools",