Skip to content

Commit 049499a

Browse files
committed
fix(storm-ops): Ensure we do not format generator files
1 parent ddc5639 commit 049499a

1 file changed

Lines changed: 6 additions & 11 deletions

File tree

lefthook.yml

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,7 @@ pre-commit:
3030
stage_fixed: true
3131
schema-gen:
3232
glob: "packages/config/src/schema.ts"
33-
run:
34-
'pnpm nx generate @storm-software/workspace-tools:config-schema
33+
run: 'pnpm nx generate @storm-software/workspace-tools:config-schema
3534
--outputFile="./packages/config/schemas/storm.schema.json" && git
3635
update-index'
3736
stage_fixed: true
@@ -61,8 +60,7 @@ pre-commit:
6160
format:
6261
files: "git diff --name-only HEAD @{push}"
6362
glob: "!packages/workspace-tools/src/generators/*/files/**/*"
64-
run:
65-
"pnpm exec prettier {staged_files} --write --ignore-unknown
63+
run: "pnpm exec prettier {staged_files} --write --ignore-unknown
6664
--no-error-on-unmatched-pattern --cache && git update-index"
6765
stage_fixed: true
6866
# postbuild:
@@ -73,8 +71,7 @@ pre-commit:
7371
commit-msg:
7472
commands:
7573
validate:
76-
run:
77-
'pnpm exec commitlint
74+
run: 'pnpm exec commitlint
7875
--config="./dist/packages/git-tools/commitlint/commitlint.config.cjs"
7976
--edit {1}'
8077

@@ -84,15 +81,13 @@ pre-push:
8481
validate:
8582
files: "git diff --name-only HEAD @{push}"
8683
glob: "**/*"
87-
run:
88-
"node ./dist/packages/git-tools/bin/pre-push.js {files} && git
84+
run: "node ./dist/packages/git-tools/bin/pre-push.js {files} && git
8985
update-index"
9086
stage_fixed: true
9187
format:
9288
files: "git diff --name-only HEAD @{push}"
93-
glob:
94-
run:
95-
"pnpm exec prettier {files} --write --ignore-unknown
89+
glob: "!packages/workspace-tools/src/generators/*/files/**/*"
90+
run: "pnpm exec prettier {files} --write --ignore-unknown
9691
--no-error-on-unmatched-pattern --cache && git update-index"
9792
stage_fixed: true
9893
build:

0 commit comments

Comments
 (0)