-
Notifications
You must be signed in to change notification settings - Fork 411
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
Insert keymap doesnt work #1485
Comments
Please apply this patch and build Yazi in debug mode, then check the log file to see what key was reported --- yazi/yazi-fm/src/app/app.rs
+++ yazi/yazi-fm/src/app/app_new.rs
@@ -81,7 +81,10 @@
fn dispatch_render(&mut self) { NEED_RENDER.store(true, Ordering::Relaxed); }
#[inline]
- fn dispatch_key(&mut self, key: KeyEvent) { Router::new(self).route(Key::from(key)); }
+ fn dispatch_key(&mut self, key: KeyEvent) {
+ tracing::error!(?key);
+ Router::new(self).route(Key::from(key));
+ }
#[inline]
fn dispatch_paste(&mut self, str: String) { |
I did it, but I nothing special, when I press Insert:
|
When you press other keys, do they also not appear in the log? If so, it's likely that you didn't apply the patch correctly |
Other keys also not appear. Hmm...I do the following commands:
|
Try applying the patch manually not using |
Now working the log, but doesnt show about Insert key:
When press Num Lock, then working Insert/0 key, show 0, see log. When switch to Insert key with Num Lock, doesnt show anythig. But I use lf file manager, then Insert key is working. |
In this case I think it's likely a bug of crossterm, because Yazi just receives key events from crossterm as they are without doing any extra processing. If it doesn't appear in the logs, it means Yazi didn't receive it at all, I don't think there's anything Yazi can do about this. I suggest you submit an issue to crossterm so that its devs can investigate it further. |
Come response for your suggestion: You may be able to get this to work in some terminals (but not all) by turning on the keyboard enhancement flags - this would be something that yazi would have to do (and it still may not solve your problem). You may be able to configure your terminal to do something special with Insert however and then configure yazi to recognize that. I'm closing this as a duplicate of crossterm-rs/crossterm#685 - you can add a comment there to help track this, but given this is in the keys not really supported by default you might be out of luck for really doing anything useful." |
Does your |
I saw that, but couldnt find information from it. I think doesnt support, because the st's philosophy is be simple and small. So I tried Alacritty, and Insert is worked. So, this function doesnt work my best terminal :( Thx for your help. |
I'm going to lock this issue because it has been closed for 30 days. ⏳ |
What system are you running Yazi on?
Linux X11
What terminal are you running Yazi in?
st 0.9.1
yazi --debug
outputDid you try the latest nightly build to see if the problem got fixed?
Yes, and I updated the debug information above (
yazi --debug
) to the nightly that I triedDescribe the bug
When I mount Insert keyboard to the create function, it doesnt work/nothing happaned.
{ on = [ "<Insert>" ], run = "create", desc = "Create a file or directory (ends with / for directories)" },
Minimal reproducer
I use this code:
{ on = [ "<Insert>" ], run = "create", desc = "Create a file or directory (ends with / for directories)" },
Anything else?
No response
The text was updated successfully, but these errors were encountered: