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 spellcheck to CI #3557

Closed
wants to merge 4 commits into from
Closed

Add spellcheck to CI #3557

wants to merge 4 commits into from

Conversation

notgull
Copy link
Member

@notgull notgull commented Mar 2, 2024

winit is a large codebase and manually checking for typos is infeasible.
This commit adds a spellcheck hook using cspell to the CI. That way we
can be sure that there are no typos in our code before we commit.


WIP until I fix all of the typos.

  • Tested on all platforms changed
  • Added an entry to CHANGELOG.md if knowledge of this change could be valuable to users
  • Updated documentation to reflect any user-facing changes, including notes of platform-specific behavior
  • Created or updated an example program if it would help users understand this functionality
  • Updated feature matrix, if new features were added or implemented

notgull added 2 commits March 2, 2024 09:38
winit is a large codebase and manually checking for typos is infeasible.
This commit adds a spellcheck hook using cspell to the CI. That way we
can be sure that there are no typos in our code before we commit.

Signed-off-by: John Nunley <[email protected]>
@notgull notgull marked this pull request as draft March 2, 2024 17:42
src/platform/wayland.rs Outdated Show resolved Hide resolved
@@ -82,7 +82,7 @@ pub trait WindowExtWebSys {
/// would prevent that.
///
/// Some events are impossible to prevent. E.g. Firefox allows to access the native browser
/// context menu with Shift+Rightclick.
/// context menu with Shift+Right-click.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks arbitrary.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally for combination words (like Rightclick) I try to split it into two words unless it isn't possible (it's part of public API).

src/platform/web.rs Outdated Show resolved Hide resolved
@notgull notgull marked this pull request as ready for review March 3, 2024 06:31
notgull added a commit to rust-windowing/raw-window-handle that referenced this pull request Mar 3, 2024
In order to ensure that typos are not introduced in future commits,
this commit adds a spellchecker to CI.

See also: rust-windowing/winit#3557

Signed-off-by: John Nunley <[email protected]>
notgull added a commit to rust-windowing/softbuffer that referenced this pull request Mar 3, 2024
This commit adds a spellchecker to the CI pipeline. This prevents typos
from being made in future commits.

See also: rust-windowing/winit#3557

Signed-off-by: John Nunley <[email protected]>
Copy link
Member

@daxpedda daxpedda left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've used cargo-spellcheck and typos before, but this one looks good as well.

This is great!

@@ -150,7 +151,7 @@ pub(crate) fn create_key_event(

let logical_key = match text_with_all_modifiers.as_ref() {
// Only checking for ctrl and cmd here, not checking for alt because we DO want to
// include its effect in the key. For example if -on the Germay layout- one
// include its effect in the key. For example if -on the Germany layout- one
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// include its effect in the key. For example if -on the Germany layout- one
// include its effect in the key. For example if -on the German layout- one

@@ -17,7 +17,7 @@ use windows_sys::{
pub struct IUnknownVtbl {
pub QueryInterface: unsafe extern "system" fn(
This: *mut IUnknown,
riid: *const GUID,
r_iid: *const GUID,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have a feeling that these are all named after the corresponding arguments in Win32?

@kchibisov
Copy link
Member

Closing in favor of #3565

@kchibisov kchibisov closed this Mar 5, 2024
notgull added a commit to rust-windowing/softbuffer that referenced this pull request Mar 12, 2024
This commit adds a spellchecker to the CI pipeline. This prevents typos
from being made in future commits.

See also: rust-windowing/winit#3557

Signed-off-by: John Nunley <[email protected]>
notgull added a commit to rust-windowing/raw-window-handle that referenced this pull request Mar 13, 2024
In order to ensure that typos are not introduced in future commits,
this commit adds a spellchecker to CI.

See also: rust-windowing/winit#3557

Signed-off-by: John Nunley <[email protected]>
notgull added a commit to rust-windowing/softbuffer that referenced this pull request Mar 13, 2024
This commit adds a spellchecker to the CI pipeline. This prevents typos
from being made in future commits.

See also: rust-windowing/winit#3557

Signed-off-by: John Nunley <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants