Skip to content
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 codespell #40

Merged
merged 2 commits into from
Nov 19, 2024
Merged

Add codespell #40

merged 2 commits into from
Nov 19, 2024

Conversation

jpthiele
Copy link
Contributor

This adds support for codespell,
which is a spellchecker based on a dictionary of common typos.

The first commit adds a .codespellrc configuration file,
which makes codespell ignore two common typos:

  • rcall for recall
  • missings for missing
    as both are Julia package names we use throughout pdelib.

The second commit amends the legitimate typos codespell has found.

@jpthiele
Copy link
Contributor Author

Codespell can be installed through conda-forge or pip and can be run in the main repo folder with
codespell . if you want to see how it flagged the errors
With codespell -w . the fixes can be applied directly if all are clear.

@jpthiele jpthiele requested review from j-fu and pjaap November 19, 2024 10:50
@jpthiele
Copy link
Contributor Author

In the future we could add our own dictionary as well if needed.
E.g. for typos like Voroni or Makei but we can do that whenever such a typo comes up.

@jpthiele
Copy link
Contributor Author

@j-fu @chmerdon I'm happy to add such a PR to each of your repos if you want.

@pjaap
Copy link
Member

pjaap commented Nov 19, 2024

Thanks for setting this up. I would go one further and activate this for CI. Can you add this as a third commit?

@chmerdon
Copy link
Member

@jpthiele Please do, thx

@jpthiele
Copy link
Contributor Author

Thanks for setting this up. I would go one further and activate this for CI. Can you add this as a third commit?

My current plan is to add a follow-up PR with a .pre-commit-config.yml with both Runic.jl and codespell, as well as a few other small useful hooks, each as individual commits so we can pick and choose. It will also have a pre-commit CI file

@pjaap
Copy link
Member

pjaap commented Nov 19, 2024

Ok, then this is now basically a spell fix PR, so I would merge this.

@pjaap pjaap merged commit 832bac8 into WIAS-PDELib:main Nov 19, 2024
8 checks passed
@jpthiele jpthiele deleted the codespell branch November 19, 2024 12:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants