-
Notifications
You must be signed in to change notification settings - Fork 104
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
feat(action): Add support for force-exclude option #1096
base: master
Are you sure you want to change the base?
Conversation
As for this change, I wonder if we should unconditionally set it like we do with pre-commit.
I'd be curious to see your setup for this |
Pull Request Test Coverage Report for Build 10783793421Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
This is our current
The goal is to only check the spelling for files that were changed in the pull request. This reduces the number of files to process, allowing for quicker feedback. |
How much of a time difference does that make? |
@epage Sorry, after double-checking, there’s no noticeable time difference between running typos with a diff versus running it on all files. However, our repositories include YAML files and settings that contain other languages and base64 strings, which are incorrectly flagged as typos. We need to ignore these to prevent the check from failing every time. Here are some examples:
|
Sounds like filtering what files are checked masks problems
Seems like that should be fixed more generally, see https://github.com/crate-ci/typos?tab=readme-ov-file#false-positives. In particular, our refernece has examples of regexes to create directives for disabling typos within sections of files. |
When using typos with changed-files, the `extend-exclude` setting in the configuration file is ignored, leading to checks on unwanted directories. This update ensures ensurs target directories are consistently ignored and avoids unnecessary validations.
@epage, I think there might be a slight misunderstanding regarding my patch. In our GitHub workflow, we are using typos in combination with changed-files to check only the files modified in a PR. |
If the performance difference is negligable, why then care? I had thought the statement about YAML files was about why you cared but that appears to not be the case. |
When using typos with changed-files, the
extend-exclude
setting in the configuration file is ignored, leading to checks on unwanted directories.This update ensures target directories are consistently ignored and avoids unnecessary validations.