Capture initial Enter key release#59
Merged
LegNeato merged 1 commit intoRust-GPU:mainfrom Mar 30, 2025
Merged
Conversation
LegNeato
requested changes
Mar 30, 2025
LegNeato
left a comment
There was a problem hiding this comment.
Thanks! Small nit, looks like it is failing CI:
error: using `print!()` with a format string that ends in a single newline
--> crates/cargo-gpu/src/spirv_cli.rs:219:9
|
219 | print!("\n");
| ^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#print_with_newline
= note: `-D clippy::print-with-newline` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(clippy::print_with_newline)]`
help: use `println!` instead
|
219 - print!("\n");
219 + println!();
bee82ee to
7f71bc3
Compare
Contributor
Author
Hmm... I can remove the newline in the diff to get CI passing, but the output does look a little weird when there are no line breaks. Any suggestion on how to proceed here? |
|
I think |
7f71bc3 to
56b8c0c
Compare
# Conflicts: # crates/cargo-gpu/src/spirv_cli.rs
56b8c0c to
94c3f34
Compare
Contributor
Author
|
Appears that lints are now passing. |
|
Wfm, thanks! |
LegNeato
approved these changes
Mar 30, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of some minor issues I ran into in #58:
When installing with Powershell,
cargo gpu buildwill be started with an Enter keydown, but has an opportunity to observe the corresponding Enter keyup event too (see crossterm-rs/crossterm#124). When this happens, it's impossible runcargo gpu buildwithout--auto-install-rust-toolchainbecause I'm unable to press "y".I don't think it's ever expected for the first interaction in a terminal to be a keyup event, so maybe we can just re-read the input if that happens?