diff --git a/.husky/pre-commit b/.husky/pre-commit new file mode 100644 index 000000000..eb90fc3a2 --- /dev/null +++ b/.husky/pre-commit @@ -0,0 +1 @@ +pnpm run lint && pnpm run typecheck diff --git a/package.json b/package.json index 84f50e0a5..fd8269206 100644 --- a/package.json +++ b/package.json @@ -8,12 +8,15 @@ "scripts": { "build": "turbo run build", "lint": "turbo run lint", + "typecheck": "turbo run tsc", "fix": "turbo run fix", "test": "turbo run test --no-cache --concurrency=1", - "test:integration": "turbo run test:integration --no-cache" + "test:integration": "turbo run test:integration --no-cache", + "prepare": "husky" }, "devDependencies": { "@changesets/cli": "2.29.6", + "husky": "^9.1.7", "turbo": "^1.10.13" }, "engines": { diff --git a/packages/eslint-config-story/package.json b/packages/eslint-config-story/package.json index 3a4788755..6bc83b937 100644 --- a/packages/eslint-config-story/package.json +++ b/packages/eslint-config-story/package.json @@ -17,7 +17,8 @@ "eslint-plugin-tsdoc": "^0.4.0", "globals": "^16.1.0", "prettier": "^3.5.3", - "typescript-eslint": "^8.32.0" + "typescript-eslint": "^8.32.0", + "eslint-plugin-turbo": "^1.13.4" }, "peerDependencies": { "@eslint/js": "^9.26.0" @@ -25,4 +26,4 @@ "exports": { "default": "./index.js" } -} +} \ No newline at end of file diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index e54027c62..e577d7759 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -45,6 +45,9 @@ importers: '@changesets/cli': specifier: 2.29.6 version: 2.29.6(@types/node@20.19.9) + husky: + specifier: ^9.1.7 + version: 9.1.7 turbo: specifier: ^1.10.13 version: 1.13.4 @@ -190,6 +193,9 @@ importers: eslint-plugin-tsdoc: specifier: ^0.4.0 version: 0.4.0 + eslint-plugin-turbo: + specifier: ^1.13.4 + version: 1.13.4(eslint@9.27.0) globals: specifier: ^16.1.0 version: 16.1.0 @@ -3638,6 +3644,11 @@ packages: resolution: {integrity: sha512-3gKm/gCSUipeLsRYZbbdA1BD83lBoWUkZ7G9VFrhWPAU76KwYo5KR8V28bpoPm/ygy0x5/GCbpRQdY7VLYCoIg==} hasBin: true + husky@9.1.7: + resolution: {integrity: sha512-5gs5ytaNjBrh5Ow3zrvdUUY+0VxIuWVL4i9irt6friV+BqdCfmV11CQTWMiBYWHbXhco+J1kHfTOUkePhCDvMA==} + engines: {node: '>=18'} + hasBin: true + i18next-browser-languagedetector@7.1.0: resolution: {integrity: sha512-cr2k7u1XJJ4HTOjM9GyOMtbOA47RtUoWRAtt52z43r3AoMs2StYKyjS3URPhzHaf+mn10hY9dZWamga5WPQjhA==} @@ -10945,6 +10956,8 @@ snapshots: human-id@4.1.1: {} + husky@9.1.7: {} + i18next-browser-languagedetector@7.1.0: dependencies: '@babel/runtime': 7.27.6 diff --git a/turbo.json b/turbo.json index 253fd5c54..ea0831873 100644 --- a/turbo.json +++ b/turbo.json @@ -10,6 +10,7 @@ }, "lint": {}, "lint:fix": {}, + "tsc": {}, "test": {}, "test:integration": {}, "dev": {