44
55** Smart man page lookup for zsh vi mode**
66
7- Press ` K ` on any command or option to instantly open its man page—just like in vim!
7+ Press ` Shift- K` on any command or option to instantly open its man page
88
99[ ![ License: MIT] ( https://img.shields.io/badge/License-MIT-blue.svg )] ( LICENSE )
1010[ ![ Zsh] ( https://img.shields.io/badge/Shell-Zsh-green.svg )] ( https://www.zsh.org/ )
@@ -24,7 +24,9 @@ Press `K` on any command or option to instantly open its man page—just like in
2424<td width =" 50% " >
2525
2626### 🎯 Smart Detection
27+
2728Automatically finds the right man page for subcommands
29+
2830```
2931git commit → man git-commit
3032docker run → man docker-run
@@ -34,9 +36,11 @@ docker run → man docker-run
3436<td width =" 50% " >
3537
3638### 🔍 Option Jumping
39+
3740Opens man page directly at the option definition
41+
3842```
39- grep -r → jumps to -r entry
43+ grep -r → jumps to -r entry
4044ls --color → jumps to --color entry
4145```
4246
@@ -46,20 +50,24 @@ ls --color → jumps to --color entry
4650<td width =" 50% " >
4751
4852### 🔗 Combined Options
53+
4954Works with combined short options
55+
5056```
51- rm -rf → finds both -r and -f
52- tar -xvf → finds -x, -v, -f
57+ rm -rf → finds both -r and -f
58+ tar -xvf → finds -x, -v, -f
5359```
5460
5561</td >
5662<td width =" 50% " >
5763
5864### 📝 Value Extraction
65+
5966Handles options with values
67+
6068```
61- --color=always → searches --color
62- --output=file.txt → searches --output
69+ --color=always → searches --color
70+ --output=file.txt → searches --output
6371```
6472
6573</td >
@@ -68,17 +76,21 @@ Handles options with values
6876<td width =" 50% " >
6977
7078### 🔀 Pipe Support
79+
7180Detects correct command in pipelines
81+
7282```
73- cat file | grep -i → opens man grep
74- tree | less -N → opens man less
83+ cat file | grep -i → opens man grep
84+ tree | less -N → opens man less
7585```
7686
7787</td >
7888<td width =" 50% " >
7989
8090### 🛠️ Multiple Formats
91+
8192Supports various man page styles
93+
8294```
8395GNU: -R, -r, --recursive
8496jq: --slurp / -s:
@@ -99,15 +111,18 @@ find: -name, -type, -exec
99111``` zsh
100112zinit light TunaCuma/zsh-vi-man
101113```
114+
102115</details >
103116
104117<details >
105118<summary ><b >antidote</b ></summary >
106119
107120Add to your ` .zsh_plugins.txt ` :
121+
108122```
109123TunaCuma/zsh-vi-man
110124```
125+
111126</details >
112127
113128<details >
@@ -119,9 +134,11 @@ git clone https://github.com/TunaCuma/zsh-vi-man \
119134```
120135
121136Then add to your ` .zshrc ` :
137+
122138``` zsh
123139plugins=(... zsh-vi-man)
124140```
141+
125142</details >
126143
127144<details >
@@ -131,6 +148,7 @@ plugins=(... zsh-vi-man)
131148git clone https://github.com/TunaCuma/zsh-vi-man ~ /.zsh-vi-man
132149echo ' source ~/.zsh-vi-man/zsh-vi-man.plugin.zsh' >> ~ /.zshrc
133150```
151+
134152</details >
135153
136154<br >
@@ -146,14 +164,14 @@ echo 'source ~/.zsh-vi-man/zsh-vi-man.plugin.zsh' >> ~/.zshrc
146164
147165### Examples
148166
149- | Command | Cursor On | Result |
150- | :--------| :----------| :-------|
151- | ` ls -la ` | ` ls ` | Opens ` man ls ` |
152- | ` ls -la ` | ` -la ` | Opens ` man ls ` , jumps to ` -l ` |
153- | ` git commit --amend ` | ` commit ` | Opens ` man git-commit ` |
154- | ` grep --color=auto ` | ` --color=auto ` | Opens ` man grep ` , jumps to ` --color ` |
155- | ` cat file \| sort -r ` | ` -r ` | Opens ` man sort ` , jumps to ` -r ` |
156- | ` find . -name "*.txt" ` | ` -name ` | Opens ` man find ` , jumps to ` -name ` |
167+ | Command | Cursor On | Result |
168+ | :--------------------- | :------------- | :----------------------------------- |
169+ | ` ls -la ` | ` ls ` | Opens ` man ls ` |
170+ | ` ls -la ` | ` -la ` | Opens ` man ls ` , jumps to ` -l ` |
171+ | ` git commit --amend ` | ` commit ` | Opens ` man git-commit ` |
172+ | ` grep --color=auto ` | ` --color=auto ` | Opens ` man grep ` , jumps to ` --color ` |
173+ | ` cat file \| sort -r ` | ` -r ` | Opens ` man sort ` , jumps to ` -r ` |
174+ | ` find . -name "*.txt" ` | ` -name ` | Opens ` man find ` , jumps to ` -name ` |
157175
158176<br >
159177
0 commit comments