1,020 B
1,020 B
smart-enter.yazi
Open
files or enter
directories all in one key!
Installation
ya pack -a yazi-rs/plugins:smart-enter
Usage
Bind your l key to the plugin, in your ~/.config/yazi/keymap.toml
:
[[manager.prepend_keymap]]
on = "l"
run = "plugin smart-enter"
desc = "Enter the child directory, or open the file"
Advanced
By default, --hovered
is passed to the open
command, make the behavior consistent with enter
avoiding accidental triggers,
which means both will only target the currently hovered file.
If you still want open
to target multiple selected files, add this to your ~/.config/yazi/init.lua
:
require("smart-enter"):setup {
open_multi = true,
}
License
This plugin is MIT-licensed. For more information check the LICENSE file.