A yazi plugin to cd to the root dir of a git repository.
Run one of the following commands.
ya pack -a ayvi-0001/git-cd-root-dir
git clone https://github.com/ayvi-0001/git-cd-root-dir.yazi.git ~/.config/yazi/plugins/git-cd-root-dir.yazi
git clone https://github.com/ayvi-0001/git-cd-root-dir.yazi.git %AppData%\yazi\config\plugins\git-cd-root-dir.yazi
Add one of the following keybinds to your keymap.toml
.
# As an inline table:
[manager]
prepend_keymap = [
{ on = ["g", "r"], run = "plugin git-cd-root-dir", desc = "Goto git root directory" }
]
# or as an array of tables:
[[manager.prepend_keymap]]
on = ["g", "r"]
run = "plugin git-cd-root-dir"
desc = "Goto git root directory"
The default location is ~/.config/yazi/
on Unix-like systems, and %AppData%\yazi\config\
on Windows.