Skip to content

Commit

Permalink
feat: add lerna clean for clean:full and build:full scripts
Browse files Browse the repository at this point in the history
With loopback-next monorepo, sometimes we have to switch between branches
that have different packages. It becomes problematic to ensure clean states.

This PR adds some scripts to solve the issue:

- npm run clean:full (triggers lerna clean to remove all node_modules)
- npm run build:full (run full clean, lerna bootstrap, build, test, and lint)
  • Loading branch information
raymondfeng committed Jan 16, 2018
1 parent 4c48ece commit 3b7183e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,10 @@
"prettier:check": "npm run prettier:cli -- -l",
"prettier:fix": "npm run prettier:cli -- --write",
"clean": "lerna run --loglevel=silent clean",
"clean:full": "npm run clean && lerna clean --yes --loglevel=silent",
"build": "lerna run --loglevel=silent build",
"build:current": "lerna run --loglevel=silent build:current",
"build:full": "npm run clean && npm run build && npm run mocha && npm run lint",
"build:full": "npm run clean:full && npm run bootstrap && npm run build && npm run mocha && npm run lint",
"pretest": "npm run clean && npm run build:current",
"test": "node packages/build/bin/run-nyc npm run mocha",
"mocha": "node packages/build/bin/select-dist mocha --opts test/mocha.opts \"packages/*/DIST/test/**/*.js\" \"packages/cli/test\"",
Expand Down

0 comments on commit 3b7183e

Please sign in to comment.