-
|
I'm trying to use cspell to spell check a commit message, as shown in the cspell docs: exec npx cspell --no-summary --no-progress --language-id commit-msg $1I'm using lefthook, so I converted that to a commit-msg:
jobs:
- name: spellcheck
run: pnpm exec cspell --no-must-find-files {1}This should fail, but actually passes: I'm also using cspell in a It seems like cspell is not receiving anything to check, but I know that Is this a bug? Any suggestions? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
|
I isolated the problem to this one line in "ignorePaths": [".git/", "node_modules/", "pnpm-lock.yaml"]When that is present, I get the incorrect behaviour. When removed, the hook works. Is this a bug? |
Beta Was this translation helpful? Give feedback.
-
|
I suggest using the commit-msg:
jobs:
- name: spellcheck
run: pnpm exec cspell --no-must-find-files --file {1}There are more examples here: https://github.com/streetsidesoftware/cspell-cli |
Beta Was this translation helpful? Give feedback.
@lonix1,
The issue is
".git/". It prevents checking commit messages. This is related to #8937.