diff --git a/.githooks/init-repo.sh b/.githooks/init-repo.sh index 5f24278f..7ea301f5 100755 --- a/.githooks/init-repo.sh +++ b/.githooks/init-repo.sh @@ -31,6 +31,7 @@ fi; echo It may going for a long time. Plese wait... .githooks/gen-file-from-example.mts -nx reset lerna list +set +e +nx reset echo init done diff --git a/bin-hashbang.js b/bin-hashbang.js index d311a9bf..24d681df 100644 --- a/bin-hashbang.js +++ b/bin-hashbang.js @@ -3,7 +3,7 @@ import { basename } from 'node:path' import { readFile, writeFile } from 'node:fs/promises' import assert from 'node:assert' -import pkg from './package.json' assert { type: 'json' } +import pkg from './package.json' with { type: 'json' } let name = pkg.name @@ -58,7 +58,6 @@ function parseName(name) { else { throw new TypeError('name invalid') } - return name } diff --git a/eslint.config.mjs b/eslint.config.mjs index e2510761..ccf8ea5d 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -13,7 +13,8 @@ const srcRules = { optionalDependencies: false, bundledDependencies: false, packageDir: [ - './', + '.', + await genModuleAbsolutePathIfExists(projectDir, 'node_modules/@waiting/shared-core') ?? '.', await genModuleAbsolutePathIfExists(projectDir, 'node_modules/@mwcp/share') ?? '.', ], }], diff --git a/package.json b/package.json index 4338cc5e..9543f0cc 100644 --- a/package.json +++ b/package.json @@ -7,26 +7,25 @@ "devDependencies": { "@commitlint/cli": "19", "@commitlint/config-conventional": "19", - "@midwayjs/mock": "^3.15.8", - "@midwayjs/swagger": "^3.15.8", - "@midwayjs/validate": "^3.15.8", + "@midwayjs/mock": "^3.16.0", + "@midwayjs/swagger": "^3.16.1", + "@midwayjs/validate": "^3.16.1", "@types/koa": "2", "@types/koa": "2", "@types/mocha": "10", "@types/node": "20", - "@waiting/eslint-config": "^10.25.0", - "@waiting/shared-core": "^23.5.1", - "@waiting/shared-types": "^23.4.0", + "@waiting/eslint-config": "^10.25.1", + "@waiting/shared-core": "^23.8.0", + "@waiting/shared-types": "^23.6.0", "autocannon": "7", "coveralls": "3", "cross-env": "7", - "debug": "^4.3.4", "eslint": "8", "mocha": "10", "mocha-lcov-reporter": "1", - "mwtsc": "^1.7.2", + "mwtsc": "^1.8.1", "nx": "18", - "swagger-ui-dist": "^5.16.2", + "swagger-ui-dist": "^5.17.6", "ts-node": "^10.9.2", "tsc-alias": "^1.8.8", "typescript": "^5.4.5" diff --git a/packages/mw-demo/package.json b/packages/mw-demo/package.json index 1cd5980d..e8173b25 100644 --- a/packages/mw-demo/package.json +++ b/packages/mw-demo/package.json @@ -32,8 +32,8 @@ }, "license": "MIT", "dependencies": { - "@mwcp/otel": "25 - 26", - "@mwcp/share": "25 - 26" + "@mwcp/otel": "^26.5.0", + "@mwcp/share": "^26.5.0" }, "devDependencies": { }, diff --git a/rollup.config.js b/rollup.config.js index 2d7c82c8..cfe54a54 100644 --- a/rollup.config.js +++ b/rollup.config.js @@ -1,7 +1,7 @@ import { basename, dirname } from 'node:path' import assert from 'node:assert' -import pkg from './package.json' assert { type: 'json' } +import pkg from './package.json' with { type: 'json' } // `npm run build` -> `production` is true // `npm run dev` -> `production` is false