diff --git a/package-lock.json b/package-lock.json index 2cd45b87..e341e092 100644 --- a/package-lock.json +++ b/package-lock.json @@ -28824,10 +28824,12 @@ "@types/node": "^17.0.35", "@types/sinon-chai": "^3.2.5", "chai": "^4.5.0", + "depcheck": "^1.4.7", "eslint": "^7.25.0", "gen-esm-wrapper": "^1.1.1", "mocha": "^8.4.0", "node-machine-id": "^1.1.12", + "prettier": "^3.5.3", "ts-node": "^10.9.2", "typescript": "^5.0.4" } @@ -46704,11 +46706,13 @@ "@types/node": "^17.0.35", "@types/sinon-chai": "^3.2.5", "chai": "^4.5.0", + "depcheck": "^1.4.7", "eslint": "^7.25.0", "gen-esm-wrapper": "^1.1.1", "mocha": "^8.4.0", "node-addon-api": "^8.0.0", "node-machine-id": "^1.1.12", + "prettier": "^3.5.3", "ts-node": "^10.9.2", "typescript": "^5.0.4" }, diff --git a/packages/native-machine-id/.depcheckrc b/packages/native-machine-id/.depcheckrc new file mode 100644 index 00000000..e0a161ac --- /dev/null +++ b/packages/native-machine-id/.depcheckrc @@ -0,0 +1,9 @@ +ignores: + - '@mongodb-js/prettier-config-devtools' + - '@mongodb-js/tsconfig-devtools' + - '@types/chai' + - '@types/sinon-chai' + - 'sinon' + - 'node-addon-api' +ignore-patterns: + - 'dist' diff --git a/packages/native-machine-id/package.json b/packages/native-machine-id/package.json index 73a700e9..46cca14b 100644 --- a/packages/native-machine-id/package.json +++ b/packages/native-machine-id/package.json @@ -9,13 +9,17 @@ "bootstrap": "npm run compile", "pretest": "npm run compile", "install": "node-gyp rebuild", + "prettier": "prettier", + "typecheck": "tsc --noEmit", "test": "mocha", "test-cov": "nyc -x \"**/*.spec.*\" --reporter=lcov --reporter=text --reporter=html npm run test", "test-ci": "npm run test-cov", "lint": "eslint . && prettier --check .", - "check": "npm run lint && npm run test", + "depcheck": "depcheck", + "check": "npm run typecheck && npm run lint && npm run depcheck", "prepublishOnly": "npm run compile", - "benchmark": "ts-node scripts/benchmark.ts" + "benchmark": "ts-node scripts/benchmark.ts", + "reformat": "npm run prettier -- --write ." }, "author": "Compass Team ", "gypfile": true, @@ -50,17 +54,17 @@ "@mongodb-js/mocha-config-devtools": "^1.0.5", "@mongodb-js/prettier-config-devtools": "^1.0.2", "@mongodb-js/tsconfig-devtools": "^1.0.3", - "@types/chai": "^4.2.21", "@types/mocha": "^9.1.1", "@types/node": "^17.0.35", "@types/sinon-chai": "^3.2.5", - "chai": "^4.5.0", "eslint": "^7.25.0", "gen-esm-wrapper": "^1.1.1", "mocha": "^8.4.0", + "depcheck": "^1.4.7", "node-machine-id": "^1.1.12", - "ts-node": "^10.9.2", - "typescript": "^5.0.4" + "prettier": "^3.5.3", + "typescript": "^5.0.4", + "ts-node": "^10.9.2" }, "keywords": [ "machine id",