Skip to content

Commit 61243b6

Browse files
committed
chore: use concurrently for the build process
concurrently allows running independent tasks in parallel in different node.js processes. This can reduce execution time drastically. In my machine it reduces the `npm run check` command execution time to a half. ``` Without concurrently: real 0m20.025s user 0m41.886s sys 0m1.882s With concurrently: real 0m9.910s user 0m59.061s sys 0m2.201s ```
1 parent d189734 commit 61243b6

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

package-lock.json

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,14 +37,13 @@
3737
"prepare": "npm run build",
3838
"build:clean": "rm -rf dist",
3939
"build:update-package-version": "tsx scripts/updatePackageVersion.ts",
40-
"build:esm": "tsc --project tsconfig.esm.json",
40+
"build:esm": "tsc --project tsconfig.esm.json && chmod +x dist/esm/index.js",
4141
"build:cjs": "tsc --project tsconfig.cjs.json",
4242
"build:universal-package": "tsx scripts/createUniversalPackage.ts",
43-
"build:chmod": "chmod +x dist/esm/index.js",
44-
"build": "npm run build:clean && npm run build:esm && npm run build:cjs && npm run build:universal-package && npm run build:chmod",
43+
"build": "npm run build:clean && concurrently 'npm run build:esm' 'npm run build:cjs' 'npm run build:universal-package'",
4544
"inspect": "npm run build && mcp-inspector -- dist/esm/index.js",
4645
"prettier": "prettier",
47-
"check": "npm run build && npm run check:types && npm run check:lint && npm run check:format && npm run check:dependencies",
46+
"check": "concurrently 'npm run build' 'npm run check:types' 'npm run check:lint' 'npm run check:format' 'npm run check:dependencies'",
4847
"check:lint": "eslint .",
4948
"check:dependencies": "knip --strict",
5049
"check:format": "prettier -c .",

0 commit comments

Comments
 (0)