Skip to content

Commit eb0c845

Browse files
authored
feat: remove precommit hooks & move to ci (#320)
1 parent d0bc2be commit eb0c845

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

.github/workflows/main.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,12 @@ jobs:
2626
cache: 'npm' # Cache dependencies
2727
- name: Install dependencies
2828
run: npm ci
29+
- name: Check code formatting
30+
run: npm run check-format
2931
- name: Build
3032
run: npm run build
33+
- name: Check documentation is up-to-date
34+
run: npm run check-doc
3135
- name: Check storage layout
3236
run: npm run check-storage-layout
3337
- name: Test deployment

.husky/pre-commit

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1 @@
11
npx lint-staged
2-
3-
# Update Solidity documentation only if .sol files were changed.
4-
if git diff --cached --name-only | grep -E '\.sol$' > /dev/null; then
5-
npm run doc
6-
fi

package-lock.json

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

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,13 @@
1919
"verify": "npx hardhat verify",
2020
"verify:all": "npx hardhat run scripts/verify.ts",
2121
"format": "npx prettier --write .",
22+
"check-format": "npx prettier --check .",
2223
"uml": "npm run sol-to-uml && npm run puml-to-links && npm run storage-to-diagrams",
2324
"sol-to-uml": "npx zx scripts/tools/sol-to-uml.mjs",
2425
"puml-to-links": "npx zx scripts/tools/puml-to-links.mjs",
2526
"storage-to-diagrams": "bash scripts/tools/storage-to-diagrams.sh",
2627
"doc": "npx hardhat docgen",
28+
"check-doc": "npm run doc && git diff --exit-code docs/",
2729
"prerelease": "npm version prerelease --preid=rc -m 'chore: v%s'"
2830
},
2931
"files": [

0 commit comments

Comments
 (0)