Skip to content

Commit

Permalink
ci(package): build speed improvements (chimurai#776)
Browse files Browse the repository at this point in the history
* build(tsc): fix incremental build
* build(tsc): enable smart incremental builds
* ci(eslint): enable cache
* build(package): run tests before creating package
  • Loading branch information
chimurai authored May 7, 2022
1 parent c28df72 commit 03239c7
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -87,3 +87,4 @@ typings/
# End of https://www.gitignore.io/api/node

dist
tsconfig.tsbuildinfo
2 changes: 1 addition & 1 deletion .lintstagedrc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"**/*.{js,ts,md,yml,json,html}": "prettier --write",
"**/*.{js,ts}": "eslint --fix",
"**/*.{js,ts}": "eslint --cache --fix"
}
9 changes: 4 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,18 @@
"dist"
],
"scripts": {
"clean": "rm -rf dist coverage",
"clean": "rm -rf dist coverage tsconfig.tsbuildinfo .eslintcache",
"lint": "yarn prettier && yarn eslint",
"lint:fix": "yarn prettier:fix && yarn eslint:fix",
"eslint": "eslint '{src,test}/**/*.ts'",
"eslint": "eslint '{src,test}/**/*.ts' --cache",
"eslint:fix": "yarn eslint --fix",
"prettier": "prettier --list-different \"**/*.{js,ts,md,yml,json,html}\"",
"prettier:fix": "prettier --write \"**/*.{js,ts,md,yml,json,html}\"",
"prebuild": "yarn clean",
"build": "tsc",
"build": "tsc --build",
"test": "jest",
"coverage": "jest --coverage --coverageReporters=lcov",
"prepare": "husky install",
"prepack": "yarn build && rm dist/tsconfig.tsbuildinfo",
"prepack": "yarn clean && yarn test && yarn build",
"spellcheck": "npx --yes cspell --show-context --show-suggestions '**/*.*'"
},
"repository": {
Expand Down
1 change: 1 addition & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"compilerOptions": {
"rootDir": "./src",
"outDir": "./dist",
"lib": ["es2019", "es2020.bigint", "es2020.string", "es2020.symbol.wellknown"],
"module": "commonjs",
Expand Down

0 comments on commit 03239c7

Please sign in to comment.