Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/Rolv-Apneseth/bypass.yazi
Yazi plugin for skipping directories with only a single sub-directory
https://github.com/Rolv-Apneseth/bypass.yazi
Last synced: about 5 hours ago
JSON representation
Yazi plugin for skipping directories with only a single sub-directory
- Host: GitHub
- URL: https://github.com/Rolv-Apneseth/bypass.yazi
- Owner: Rolv-Apneseth
- License: mit
- Created: 2024-04-23T17:41:38.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2024-05-13T20:55:08.000Z (6 months ago)
- Last Synced: 2024-05-13T21:55:40.852Z (6 months ago)
- Language: Lua
- Homepage:
- Size: 5.86 KB
- Stars: 7
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-yazi - bypass - Yazi plugin for skipping directories with only a single sub-directory. (Plugins)
- awesome-yazi - bypass - Yazi plugin for skipping directories with only a single sub-directory. (Plugins)
README
# bypass.yazi
[Yazi](https://github.com/sxyazi/yazi) plugin for bidirectional skipping of directories which only have a single subdirectory
## Requirements
- [Yazi](https://github.com/sxyazi/yazi) v0.3.3+
## Installation
```bash
ya pack -a Rolv-Apneseth/bypass
```### Manual
```sh
# Linux / MacOS
git clone https://github.com/Rolv-Apneseth/bypass.yazi.git ~/.config/yazi/plugins/bypass.yazi
# Windows
git clone https://github.com/Rolv-Apneseth/bypass.yazi.git %AppData%\yazi\config\plugins\bypass.yazi
```## Usage
Add this to your `keymap.toml`:
```toml
[[manager.prepend_keymap]]
on = [ "L" ]
run = "plugin bypass"
desc = "Recursively enter child directory, skipping children with only a single subdirectory"
[[manager.prepend_keymap]]
on = [ "H" ]
run = "plugin bypass --args=reverse"
desc = "Recursively enter parent directory, skipping parents with only a single subdirectory"
```And that's it. You can bind any key you like, including overriding the default `enter` and `leave` bindings by setting them to `l` and `h` respectively.
Note that if you're using the [smart enter tip](https://yazi-rs.github.io/docs/tips#smart-enter) from the documentation, this plugin can replace that entirely by using this keybind instead:
```toml
[[manager.prepend_keymap]]
on = [ "l" ]
run = "plugin bypass --args=smart_enter"
desc = "Open a file, or recursively enter child directory, skipping children with only a single subdirectory"
```