All Projects → jaclu → tmux-menus

jaclu / tmux-menus

Licence: MIT license
Tmux plugin, Popup menus to help with managing your environment

Programming Languages

shell
77523 projects
python
139335 projects - #7 most used programming language
applescript
352 projects

Projects that are alternatives of or similar to tmux-menus

tmux-conf
📝 TMUX Configuration for nerds with tpm
Stars: ✭ 31 (-75%)
Mutual labels:  tmux, tmux-plugins, tmux-plugin
nested-tmux
A simple tmux configuration for nested tmux sessions
Stars: ✭ 66 (-46.77%)
Mutual labels:  tmux, tmux-plugins, tmux-plugin
tmux-suspend
Plugin that lets you suspend local tmux session, so that you can work with nested remote tmux session painlessly.
Stars: ✭ 58 (-53.23%)
Mutual labels:  tmux, tmux-plugins, tmux-plugin
tmux-base16-statusline
Tmux Base16 Statusline
Stars: ✭ 24 (-80.65%)
Mutual labels:  tmux, tmux-plugins
tmux-airline-dracula
A tmux theme for Dracula color scheme.
Stars: ✭ 33 (-73.39%)
Mutual labels:  tmux, tmux-plugin
tmux-plugin-spotify
tmux plugin displaying currently played song on Spotify (linux only)
Stars: ✭ 48 (-61.29%)
Mutual labels:  tmux, tmux-plugin
tmux super fingers
A Tmux plugin to open file links from the terminal in vim
Stars: ✭ 44 (-64.52%)
Mutual labels:  tmux, tmux-plugin
.tmux
🇫🇷 Oh my tmux! My self-contained, pretty & versatile tmux configuration made with ❤️
Stars: ✭ 15,594 (+12475.81%)
Mutual labels:  tmux, tmux-plugins
tmux-zsh-vim-titles
Unified terminal titles in tmux, zsh, and vim/nvim
Stars: ✭ 28 (-77.42%)
Mutual labels:  tmux, tmux-plugins
dotfiles
A cross-platform, modular dotfiles installer for my personal setup
Stars: ✭ 43 (-65.32%)
Mutual labels:  tmux
dotfiles
No description or website provided.
Stars: ✭ 20 (-83.87%)
Mutual labels:  tmux
dotfiles
These are my dotfiles. All the config stuff that I use is here.
Stars: ✭ 16 (-87.1%)
Mutual labels:  tmux
dotfiles
Personal dotfiles for macOS and Manjaro.
Stars: ✭ 20 (-83.87%)
Mutual labels:  tmux
cfg
my dotfiles
Stars: ✭ 26 (-79.03%)
Mutual labels:  tmux
dotstow
dotfiles managed with stow
Stars: ✭ 60 (-51.61%)
Mutual labels:  tmux
dotfiles
Personal dotfiles with configurations for sway, vim, zsh, etc.
Stars: ✭ 20 (-83.87%)
Mutual labels:  tmux
dotfiles
🔯 A collection of my rc files (tmux, neovim, zsh, fish, poetry, git, ...etc) and utilities that make everyday coding fun!
Stars: ✭ 23 (-81.45%)
Mutual labels:  tmux
dotfiles
My OSX / Linux tools and configurations
Stars: ✭ 35 (-71.77%)
Mutual labels:  tmux
dotfiles
💻dotfiles for: tmux, neovim, git, zsh, osx
Stars: ✭ 49 (-60.48%)
Mutual labels:  tmux
nvim configration
Neovim diy develop enviroment.This project integrates neovim tmux zsh and some very useful plugs of them including YouCompleteMe FZF auto pairs nerdtree ncm2 and so on.
Stars: ✭ 22 (-82.26%)
Mutual labels:  tmux

Tmux-Menus

Popup menus to help with managing your environment.

Not to hard to adopt to fit your needs. Items that some might find slightly redundant are included, easier to remove excess for more experienced users, than to add more for newbies.

Recent changes

  • Main menu, Public IP - It is simply echoed in the current pane, so that there is plenty of time to read and/or copy it. Just hit Escape to get pane to resume normal operation.
  • Plugin inventory lists uninstalled plugins, and gives instructions howto uninstall not used plugins
  • Added Plugins inventory - (main menu) Lists defined plugins, install status and items not supposed to be in plugins dir
  • Added back arrows to previous menu / main (where applicable)

Purpose

Some basic popup menus come as default (See Configuration on how to turn them off)

  • <prefix> < displays some windows handling options
  • <prefix> > displays some pane handling options
  • Right click on pane, ALT-right click on pane, status or status left.

Rather lacking and since they're written as hard to read one-liners, a more integrated approach with navigation and adaptability seemed the way to go, also covering more than panes and windows.

Not solely meant for beginners, use it myself all the time:

  • When connecting using terminals without much support for Meta or Ctrl, then this gives access to all the actions that aren't available with the normal shortcuts. For instance when running iSH the console keyboard is limited.
  • Tasks that would need external scripts to avoid hard to read complex bind one-liners, such as kill current session, without getting disconnected.
  • When direct typing would be much longer. Example: Kill the server directly is min 12 keys: <prefix> : kill-ser <tab> <enter> with the menus 5 keys: <prefix> \ A x y
  • Actions used to seldom to remember as shortcuts.

Usage

Once installed, hit the trigger to get the main menu to popup. Default is <prefix> \ see Configuration below for how to change it.

Screenshots of some menus

main Pane Window Advanced Session Help Summary

Compatibility

VersionNotice
3.2 -Fully compatible
3.0 ⁠- 3.1cMenu centering not supported, it's displayed top left if C is menu location. Some actions might not work depending on version. There should be a notification message about "unknown command" in such cases.

Install

Installation with Tmux Plugin Manager (recommended)

Add plugin to the list of TPM plugins in .tmux.conf:

set -g @plugin 'jaclu/tmux-menus'

Hit prefix + I to fetch the plugin and source it. You should now be able to use the plugin.

Manual installation

Clone the repository:

git clone https://github.com/jaclu/tmux-menus.git ~/clone/path

Add this line to the bottom of .tmux.conf:

run-shell ~/clone/path/menus.tmux

Reload TMUX environment with tmux source-file ~/.tmux.conf. You should now be able to use the plugin.

Configuration

Changing the key-bindings for this plugin

The default trigger is <prefix> \. Trigger is selected like this:

set -g @menus_trigger 'F9'

Please note that non standard keys, like the default backslash needs to be noted in a specific way in order not to confuse tmux. Either '\' or without quotes as \\. Quoting '\\' won't make sense for tmux and fail to bind any key.

If you want to trigger menus without first hitting <prefix>

set -g @menus_without_prefix 1

This param can be either 0 (the default) or 1

Menu location

Default location is: P, compatible with older tmux versions

Locations can be one of:

  • W - By the current window name in the status line
  • P - Lower left of current pane
  • C - Centered in window (tmux 3.2 and up)
  • M - Mouse position (doesn't seem to work as intended…)
  • R - Right edge of terminal (x)
  • S - Next to status line (y)
  • Number - In window coordinates 0,0 is top left. To make it even more confusing, the coordinate defines lower left of the menus placement…
set -g @menus_location_x 'C'
set -g @menus_location_y 'C'

Live config

If you want to be able to dynamically edit menu settings from within menus, set this

set -g @menus_config_overrides 1

This param can be either 0 (the default) or 1

configurable items: menu location

Default menus

To turn off the limited default popup menus, add the following

unbind-key -n MouseDown3Pane
unbind-key -n M-MouseDown3Pane
unbind-key -n MouseDown3Status
unbind-key -n MouseDown3StatusLeft
unbind-key <
unbind-key >

Making synchronized panes stand out

Not directly related to this plugin, but since it does have an option to trigger sync mode, and having it on unintendedly can ruin your day, this might be helpful. You can add this snippet to your status bar to make sync mode stand out, so that you never leave it turned on when not intended.

#[reverse,blink]#{?pane_synchronized,*** PANES SYNCED! ***,}#[default]

Modifications

If you want to experiment with changing the menus, first clone/copy this repository to a different location on your system.

Then by running ~/path/to/alternate-tmux-menus/menus.tmux, your trigger key binds to this alternate menu set. Next time you trigger the menus, this in-development menu tree is used.

Each menu is a script, so you can edit a menu script and once saved, the new content is displayed next time you trigger that menu.

Rapid development with minimal fuzz.

If you are struggling with a menu edit, run that menu item in a pane of the tmux session your working on, something like

./items/sessions.sh

This directly triggers that menu and displays any syntax errors on the command line.

In scripts/utils.sh there is a function log_it, and a variable log_file. If log_file is defined, any call to log_it is printed there. If not defined, nothing happens. log_it lines can be left in the code.

If you are triggering a menu from the command line, you can use direct echo, but then you need to remove it before deploying, since tmux sees any script output as an potential error and display it in a scroll back buffer. If tailing a log file is unpractical, a more scalable way to achieve the same result as echo would be to set log_file='/dev/stdout'

To trigger log output, add lines like:

log_it "foo is now [$foo]"

When done, first unset log_file, then copy or commit your changes to the default location, this is used from now on.

If you want to go back to your installed version for now, either reload configs, or run ~/.tmux/plugins/tmux-menus/menus.tmux to rebind those menus to the trigger. Regardless the installed version is activated next time you start tmux automatically.

Contributing

Contributions are welcome, and they're appreciated. Every little bit helps, and credit is always given.

The best way to send feedback is to file an issue at issues

Thanks to

  • giddie for suggesting "Re-spawn current pane"

License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].