From 8a3b21753030c88a6067190c09b79d5b11233e74 Mon Sep 17 00:00:00 2001 From: Jon Cinque Date: Thu, 24 Sep 2020 09:45:57 +0200 Subject: [PATCH] chore: make `lint` for checking, `lint:fix` for fixing (#12415) --- web3.js/package.json | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/web3.js/package.json b/web3.js/package.json index 2a082497ea..656305dc05 100644 --- a/web3.js/package.json +++ b/web3.js/package.json @@ -53,7 +53,7 @@ "flow:stop": "flow stop", "flow:watch": "flow stop; watch 'flow' . --wait=1 --ignoreDirectoryPattern=/doc/", "lint": "set -ex; npm run pretty; eslint . --ext .js,.ts", - "lint:fix": "npm run lint -- --fix", + "lint:fix": "npm run pretty:fix && eslint . --fix", "lint:watch": "watch 'npm run lint:fix' . --wait=1 --ignoreDirectoryPattern=/doc/", "localnet:down": "bin/localnet.sh down", "localnet:logs": "bin/localnet.sh logs -f", @@ -61,7 +61,8 @@ "localnet:update": "bin/localnet.sh update", "ok": "run-s lint flow test doc defs", "prepare": "run-s clean bpf-sdk:install bpf-sdk:remove-symlinks build", - "pretty": "prettier --write '{,{examples,src,test}/**/}*.{j,t}s'", + "pretty": "prettier --check '{,{examples,src,test}/**/}*.{j,t}s'", + "pretty:fix": "prettier --write '{,{examples,src,test}/**/}*.{j,t}s'", "re": "semantic-release --repository-url git@github.com:solana-labs/solana-web3.js.git", "test": "npm run build:fixtures && cross-env NODE_ENV=test jest --useStderr", "test:cover": "npm run build:fixtures && cross-env NODE_ENV=test jest --coverage --useStderr",