@@ -20,9 +20,13 @@ experienced users, then add more for newbies.
20
20
21
21
## Recent Changes
22
22
23
+ - Added new feature Display Commands, see ` Display menu commands ` in the Configuration
24
+ section
25
+ - Fixed handling of menu options in tmux 3.0 - 3.2a since they don't return an
26
+ error for missing options
27
+ - Added display commands feature, see Display menu commands section in
23
28
- Removed all jk shortcuts in menus, allowing for consistent vim style navigation.
24
29
- Plugin is initialized in the background, to cut down on tpm processing time.
25
- - Further optimized caching, cutting rendeing times in half.
26
30
27
31
</details >
28
32
<details >
@@ -144,63 +148,6 @@ Manager](https://github.com/tmux-plugins/tpm).
144
148
145
149
The plugin should now be activated.
146
150
147
- </details >
148
- <details >
149
- <summary >Using Styling for menus</summary >
150
- <br >
151
-
152
- ### Using Styling for menus
153
-
154
- See [ docs/Styling.md] ( docs/Styling.md )
155
-
156
- </details >
157
- <details >
158
- <summary >Custom menus</summary >
159
- <br >
160
-
161
- ## Custom Menus
162
-
163
- While the initial assumption was that users wanting to modify the menus would fork
164
- the repository and make changes directly, a feature was added to allow menus to
165
- be added dynamically based on user requests.
166
-
167
- For details on how to use this feature, see the documentation:
168
- [ docs/CustomMenus.md] ( docs/CustomMenus.md )
169
-
170
- </details >
171
- <details >
172
- <summary >whiptail / dialog</summary >
173
- <br >
174
-
175
- ## whiptail / dialog - alternate tools for displaying menus
176
-
177
- For tmux < 3.0 the tmux feature` display-menu ` is not available.
178
-
179
- If found ` whiptail ` or ` dialog ` will be used to display menus.
180
-
181
- The preferred option is whiptail, but if not found dialog will be used instead.
182
- If neither is available, this plugin will abort displaying an error message.
183
-
184
- Since these are full-screen apps, when either is used, the current (if any)
185
- task is suspended, dialogs are run, and when done the suspended task is reactivated.
186
-
187
- The menu system works the same using external menu handlers, however the menu
188
- shortcuts are not as convenient, since they do not differentiate between upper
189
- and lower case letters,
190
- and does not at all support special keys like 'Left' or 'Home'
191
-
192
- To use external dialog handling on modern tmuxes set this env variable:
193
-
194
- - for ` whiptail ` use ` export TMUX_MENUS_HANDLER=1 `
195
- - for ` dialog ` use ` export TMUX_MENUS_HANDLER=2 `
196
-
197
- In most cases whiptail is installed by default on Linux distros. If not, install
198
- it using the package manager.
199
- One gotcha is that in the Red Hat universe the package is not called whiptail,
200
- the package containing whiptail is called ` newt ` .
201
-
202
- MacOS does not come with whiptail, but it is available in the Homebrew package ` newt ` .
203
-
204
151
</details >
205
152
<details >
206
153
<summary >Configuration</summary >
@@ -239,18 +186,35 @@ as well as when not using quotes.
239
186
240
187
### Display without using prefix
241
188
242
- In order to trigger menus without first hitting ` <prefix> `
243
-
244
189
``` tmux
245
190
set -g @menus_without_prefix ' Yes'
246
191
```
247
192
248
- This boolean parameter can be either ` Yes ` or ` No ` (the default)
193
+ This boolean parameter defaults to ` No `
194
+
195
+ Use this in order to trigger menus without first hitting ` <prefix> `
196
+
197
+ ### Pointer to the config file
198
+
199
+ ``` tmux
200
+ set -g @menus_config_file ' ~/.configs/tmux.conf'
201
+ ```
202
+
203
+ In the main menu, the tmux config file to be reloaded.
204
+ The default location for this is:
205
+
206
+ 1 . ` @menus_config_file ` - if this is defined in the tmux config file, it will be used.
207
+ 2 . ` $TMUX_CONF ` - if this is present in the environment, it will be used.
208
+ 3 . ` $XDG_CONFIG_HOME/tmux/tmux.conf ` - if ` $XDG_CONFIG_HOME ` is defined.
209
+ 4 . ` ~/.tmux.conf ` - Default if none of the above are set.
210
+
211
+ When a reload is requested, the conf file will be prompted for, defaulting
212
+ to the first match above. It can be manually changed.
249
213
250
214
### Menu location
251
215
252
- The default locations are: ` C ` for tmux >= 3.2 ` P ` otherwise. If whiptail/dialog is used,
253
- menu location is ignored
216
+ The default locations are: ` C ` for tmux >= 3.2 ` P ` otherwise. If whiptail/dialog
217
+ is used, menu location is ignored
254
218
255
219
``` tmux
256
220
set -g @menus_location_x ' W'
@@ -271,13 +235,13 @@ The basic options are:
271
235
272
236
### Disable caching
273
237
274
- By default menu items are cached, set this to ` No ` to disable all caching.
275
-
276
238
``` tmux
277
239
set -g @menus_use_cache ' No'
278
240
```
279
241
280
- This boolean parameter can be either ` Yes ` (the default) or ` No `
242
+ This boolean parameter defaults to ` Yes `
243
+
244
+ By default menu items are cached.
281
245
282
246
Disabling caching also disables the Custom Menus feature.
283
247
@@ -296,26 +260,33 @@ that cache item is regenerated.
296
260
297
261
### Use Hint Overlays
298
262
263
+ ``` tmux
264
+ set -g @menus_use_hint_overlays ' No'
265
+ ```
266
+
267
+ This boolean parameter defaults to ` Yes `
268
+
299
269
Some menu items will display tmux dialogs, where each have their own rather complex
300
- set of special key bindings - choose-buffer, choose-client, choose-tree and customize-mode
270
+ set of special key bindings - choose-buffer, choose-client, choose-tree and
271
+ customize-mode
301
272
302
273
When entering such a dialog, per default an overlay will first be presented lisitng
303
274
the keys available for that dialog, if it fits on screen.
304
275
305
276
Use this setting to disable the overlay feature.
306
277
307
- ``` tmux
308
- set -g @menus_use_hint_overlays ' No'
309
- ```
310
-
311
- This boolean parameter can be either ` Yes ` (the default) or ` No `
312
-
313
278
If ` @menus_use_hint_overlays ` is enabled, there is a support option
314
- ` @menus_show_key_hints ` (defaults to 'No') that also can be toggled. If ` @menus_use_hint_overlays `
315
- is disabled, ` @menus_show_key_hints ` is ignored.
279
+ ` @menus_show_key_hints ` (defaults to 'No') that also can be toggled.
280
+ If ` @menus_use_hint_overlays ` is disabled, ` @menus_show_key_hints ` is ignored.
316
281
317
282
#### Show Key Hints
318
283
284
+ ``` tmux
285
+ set -g @menus_show_key_hints ' Yes'
286
+ ```
287
+
288
+ This boolean parameter defaults to ` No `
289
+
319
290
Related to ` @menus_use_hint_overlays ` Since those key-listings tend to be rather long
320
291
they might not fit on screen, and thus be silently skipped.
321
292
Enabling this will offer an extra option ` Key Hints ` on each menu featuring an
@@ -327,37 +298,28 @@ screen is to small, mentioning required screen size.
327
298
328
299
It will also serve as a hint as to what menu entries are expected to display an overlay.
329
300
330
- ``` tmux
331
- set -g @menus_show_key_hints ' Yes'
332
- ```
333
-
334
- This boolean parameter can be either ` Yes ` or ` No ` (the default)
301
+ ### Logging
335
302
336
- ### Pointer to the config file
303
+ Per default logging is disabled. If this is desired, provide a log file name
304
+ like this:
337
305
338
306
``` tmux
339
- set -g @menus_config_file ' ~/.configs /tmux.conf '
307
+ set -g @menus_log_file ' ~/tmp /tmux-menus.log '
340
308
```
341
309
342
- In the main menu, the tmux config file to be reloaded.
343
- The default location for this is:
310
+ ### Display menu commands
344
311
345
- 1 . ` @menus_config_file ` - if this is defined in the tmux config file, it will be used.
346
- 2 . ` $TMUX_CONF ` - if this is present in the environment, it will be used.
347
- 3 . ` $XDG_CONFIG_HOME/tmux/tmux.conf ` - if ` $XDG_CONFIG_HOME ` is defined.
348
- 4 . ` ~/.tmux.conf ` - Default if none of the above are set.
349
-
350
- When a reload is requested, the conf file will be prompted for, defaulting
351
- to the first match above. It can be manually changed.
312
+ ``` tmux
313
+ set -g @menus_display_commands ' Yes'
314
+ ```
352
315
353
- ### Logging
316
+ This boolean parameter defaults to ` No `
354
317
355
- Per default logging is disabled. If this is desired, provide a log file name
356
- like this:
318
+ If set to true each menu will include an extra item ` Display Commands ` with the
319
+ shortcut ` ! ` pressing this will display what command is used for each action.
357
320
358
- ``` tmux
359
- set -g @menus_log_file ' ~/tmp/tmux-menus.log'
360
- ```
321
+ Be aware that the menu will be taller when using this, so make sure the screen is
322
+ large enough to display it!
361
323
362
324
</details >
363
325
<details >
@@ -386,6 +348,63 @@ It will also be displayed if the menu is closed right away intentionally
386
348
or unintentionally, so there will no doubt sometimes be false positives.
387
349
If it doesn't happen the next time the menu is attempted, it can be ignored.
388
350
351
+ </details >
352
+ <details >
353
+ <summary >Using Styling for menus</summary >
354
+ <br >
355
+
356
+ ## Using Styling for menus
357
+
358
+ See [ docs/Styling.md] ( docs/Styling.md )
359
+
360
+ </details >
361
+ <details >
362
+ <summary >Custom menus</summary >
363
+ <br >
364
+
365
+ ## Custom Menus
366
+
367
+ While the initial assumption was that users wanting to modify the menus would fork
368
+ the repository and make changes directly, a feature was added to allow menus to
369
+ be added dynamically based on user requests.
370
+
371
+ For details on how to use this feature, see the documentation:
372
+ [ docs/CustomMenus.md] ( docs/CustomMenus.md )
373
+
374
+ </details >
375
+ <details >
376
+ <summary >whiptail / dialog</summary >
377
+ <br >
378
+
379
+ ## whiptail / dialog - alternate tools for displaying menus
380
+
381
+ For tmux < 3.0 the tmux feature` display-menu ` is not available.
382
+
383
+ If found ` whiptail ` or ` dialog ` will be used to display menus.
384
+
385
+ The preferred option is whiptail, but if not found dialog will be used instead.
386
+ If neither is available, this plugin will abort displaying an error message.
387
+
388
+ Since these are full-screen apps, when either is used, the current (if any)
389
+ task is suspended, dialogs are run, and when done the suspended task is reactivated.
390
+
391
+ The menu system works the same using external menu handlers, however the menu
392
+ shortcuts are not as convenient, since they do not differentiate between upper
393
+ and lower case letters,
394
+ and does not at all support special keys like 'Left' or 'Home'
395
+
396
+ To use external dialog handling on modern tmuxes set this env variable:
397
+
398
+ - for ` whiptail ` use ` export TMUX_MENUS_HANDLER=1 `
399
+ - for ` dialog ` use ` export TMUX_MENUS_HANDLER=2 `
400
+
401
+ In most cases whiptail is installed by default on Linux distros. If not, install
402
+ it using the package manager.
403
+ One gotcha is that in the Red Hat universe the package is not called whiptail,
404
+ the package containing whiptail is called ` newt ` .
405
+
406
+ MacOS does not come with whiptail, but it is available in the Homebrew package ` newt ` .
407
+
389
408
</details >
390
409
<details >
391
410
<summary >Modifications</summary >
@@ -530,8 +549,8 @@ The best way to send feedback is to file an
530
549
## Thanks to
531
550
532
551
- [ sumskyi] ( https://github.com/sumskyi ) for notifying me that the boolean check
533
- error message for invalid values lacked the significant info about what variable
534
- contained the incorrect value. Addressed in release 2.0.2
552
+ error message for invalid values lacked the significant info about what variable
553
+ contained the incorrect value. Addressed in release 2.0.2
535
554
- [ GaikwadPratik] ( https://github.com/GaikwadPratik ) for notifying me that the
536
555
Disable caching feature was broken
537
556
- [ Tony Soloveyv] ( https://github.com/tony-sol ) for spotting an unintentional
0 commit comments