Yazi plugin to use cdhist to fuzzy select and navigate from your directory history, within the Yazi terminal file manager.
Use the yazi package manager to install this plugin:
ya pack -a bulletmark/cdhist
Then add to your ~/.config/yazi/keymap.toml
:
[[manager.prepend_keymap]]
on = "<A-c>"
run = "plugin cdhist -- _ --fuzzy=fzf"
desc = "Select a directory from history using cdhist"
Make sure you have cdhist installed, and can be found in your PATH
.
The above assigns Alt-c
key mapping within yazi to bring up the fuzzy search
because it is the standard key mapping for opening fzf on
directories
and for using with
cdhist.
However, you may prefer to remap the standard z
key mapping in yazi to
replace zoxide
, or
use a spare key like the C
key.
Note fzf
is preferred for cdhist fuzzy searching, but you can also use
sk
, or fzy
in the above configuration setting. Or leave the
--fuzzy
option out to use native simple cdhist index
selection.