Skip to content

Commit

Permalink
chore: add hook for checking files format
Browse files Browse the repository at this point in the history
  • Loading branch information
sinzii committed Apr 9, 2023
1 parent 8a814c8 commit 99915d3
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

yarn check-format
3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,16 @@
"clean": "npx lerna run clean",
"test": "npx lerna run --no-bail --verbose test",
"prettify": "npx prettier --write \"{packages,scripts}/{**/*,*}.{js,ts,jsx,tsx,json}\"",
"check-format": "npx prettier --check \"{packages,scripts}/{**/*,*}.{js,ts,jsx,tsx,json}\"",
"version": "yarn generate-package-info-file",
"prepublishOnly": "yarn copy-files-to-dist",
"postinstall": "husky install",
"generate-package-info-file": "lerna exec -- node \\$LERNA_ROOT_PATH/scripts/generate-package-info-file.js",
"copy-files-to-dist": "lerna exec -- node \\$LERNA_ROOT_PATH/scripts/copy-files-to-dist.js"
},
"devDependencies": {
"@trivago/prettier-plugin-sort-imports": "^4.1.1",
"husky": "^8.0.3",
"jsdom": "^21.1.0",
"lerna": "^6.5.1",
"prettier": "^2.8.4",
Expand Down
10 changes: 10 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3736,6 +3736,7 @@ __metadata:
resolution: "coong-wallet@workspace:."
dependencies:
"@trivago/prettier-plugin-sort-imports": ^4.1.1
husky: ^8.0.3
jsdom: ^21.1.0
lerna: ^6.5.1
prettier: ^2.8.4
Expand Down Expand Up @@ -5367,6 +5368,15 @@ __metadata:
languageName: node
linkType: hard

"husky@npm:^8.0.3":
version: 8.0.3
resolution: "husky@npm:8.0.3"
bin:
husky: lib/bin.js
checksum: 837bc7e4413e58c1f2946d38fb050f5d7324c6f16b0fd66411ffce5703b294bd21429e8ba58711cd331951ee86ed529c5be4f76805959ff668a337dbfa82a1b0
languageName: node
linkType: hard

"hyphenate-style-name@npm:^1.0.3":
version: 1.0.4
resolution: "hyphenate-style-name@npm:1.0.4"
Expand Down

0 comments on commit 99915d3

Please sign in to comment.