-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add spellchecking to pre-commit hooks and linting workflow #92
Conversation
Deploying with
|
Latest commit: |
d45de8c
|
Status: | ✅ Deploy successful! |
Preview URL: | https://14535467.contributing-docs.pages.dev |
Branch Preview URL: | https://cspell.contributing-docs.pages.dev |
I'm having issues with glob pattern matching in npm scripts, probably because of this issue. Will look into this next week. |
I happened to come upon this, and I have an online linter proposed in our template repository at bitwarden/template#2. I actually disabled cspell based on past experience where it's really unwieldy to maintain. You can see some alternatives that the Mega-Linter uses at https://megalinter.io/latest/descriptors/spell/. |
Thanks @withinfocus. I see that MegaLinter can run locally, maybe we can add pre-commit hooks to your template PR, and then implement it here once we have the pattern established. (I still think pre-commit hooks are valuable for immediate feedback to the dev, whereas CI checks are more like the final check.) What do you think? |
CI vs. local linting is definitely the most contentious part of that proposed change. I haven't personally executed it locally but will give it a try to see its performance -- my concern is its heaviness and speed despite its power. Separately though it may be valuable to avoid cspell. |
This reverts commit 7069203.
Typo fixes have been moved to a separate PR, #129. I haven't had a lot of time to progress this one but I'll come back to it soon. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's fix the linting errors and this should be good.
This is because npm lifetime scripts (such as npm run) execute in bash 3.2 on OSX by default, and you need bash 4 for globstar (**). Quotes prevent the shell from interpeting it and ensure it is passed to the program itself
No New Or Fixed Issues Found |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The workflow portion looks good to me.
Objective
Add spellchecking, using cspell. Because we all make typos.
Code changes
cspell.yaml
, largely following the documentation