Improve biome checker configuration
Describe the issue
The pre-commit command shows linting issues in files that are not modified by the current commit or branch.
The weird part is it raises this issues only when there is an issue with the files you actually modified. If the issues raised by the changes you made are fixed the pre-commit doesn't show the issues with the other files you didn't modify.
I already tried
- [X] I've read and searched the documentation.
- [X] I've searched for similar filed issues in this repository.
Steps to reproduce the behavior
- Introduce a dummy and unused variable (to raise an issue within the file you modified).
- Stage the changes
git add . - Run
pre-commit run -all(this will say there is an issue with an unused var we introduced and step 1, plus a ton of other issues in other files' - Remove the unused variable we introduced in step 1 and
git add .; - Then re run the
pre-commitcommand. (now that the issue we introduced is fixed the command no longer shows the other issues in the other files'
Expected behavior
- Show only the issues with the files that are actually modified.
- The other issues should be fixed separately to avoid this behavior
Screenshots
I introduced the variable in another file. But it says there is issues with zen.js which I didn't modify.
Exception traceback
No response
How do you run Weblate?
Other
Weblate versions
No response
Weblate deploy checks
No response
Additional context
No response
I think it shows warnings, but only it fails on error. That's why you see more issues than changed. Probably biome should be configured better (either to not report warnings or to fail on them and fix underlying issues). https://biomejs.dev/guides/configure-biome/ has the documentation.
This issue has been automatically marked as stale because there wasn’t any recent activity.
It will be closed soon if no further action occurs.
Thank you for your contributions!
Thank you for your report; the issue you have reported has just been fixed.
- In case you see a problem with the fix, please comment on this issue.
- In case you see a similar problem, please open a separate issue.
- If you are happy with the outcome, don’t hesitate to support Weblate by making a donation.
Thank you for your report; the issue you have reported has just been fixed.
- In case you see a problem with the fix, please comment on this issue.
- In case you see a similar problem, please open a separate issue.
- If you are happy with the outcome, don’t hesitate to support Weblate by making a donation.