All Projects → pschmitt → tmux-slay

pschmitt / tmux-slay

Licence: other
TMUX script to run commands in a background session. Similar to abduco/dtach.

Programming Languages

shell
77523 projects

Projects that are alternatives of or similar to tmux-slay

.tmux
🇫🇷 Oh my tmux! My self-contained, pretty & versatile tmux configuration made with ❤️
Stars: ✭ 15,594 (+86533.33%)
Mutual labels:  tmux, screen
tmux-conf
📝 TMUX Configuration for nerds with tpm
Stars: ✭ 31 (+72.22%)
Mutual labels:  tmux, screen
muxed
Another TMUX project manager
Stars: ✭ 58 (+222.22%)
Mutual labels:  tmux, screen
tmux-plugin-spotify
tmux plugin displaying currently played song on Spotify (linux only)
Stars: ✭ 48 (+166.67%)
Mutual labels:  tmux
kali-config
Linux colorful dotfiles.
Stars: ✭ 40 (+122.22%)
Mutual labels:  tmux
Dot-It-Up
A collection of dotfile scripts, plugins, and clever hacks so that you can become the master of your own OS! 🚀
Stars: ✭ 254 (+1311.11%)
Mutual labels:  tmux
flutter scale aware
🎗 Scale-based layouts with a bit more ease, powered by extensions.
Stars: ✭ 26 (+44.44%)
Mutual labels:  screen
dotfiles-local
Personal configuration
Stars: ✭ 16 (-11.11%)
Mutual labels:  tmux
kube-tmuxp
Tool to generate tmuxp configs that help to switch between multiple Kubernetes contexts safely.
Stars: ✭ 21 (+16.67%)
Mutual labels:  tmux
dotfiles
My dotfiles for Bash/Zsh, Vim/Neovim, Doom Emacs, tmux, Git, terminal emulators, JupyterLab, aria2, mpv, Nix and Homebrew
Stars: ✭ 149 (+727.78%)
Mutual labels:  tmux
LXFProtocolTool
由Swift中协议方式实现功能的实用工具库【Refreshable、EmptyDataSetable 支持 Rx 】
Stars: ✭ 101 (+461.11%)
Mutual labels:  screen
dotfiles
An elegant way to manage dotfiles, commands, completions, configurations for terminal players.
Stars: ✭ 27 (+50%)
Mutual labels:  tmux
tmuxjump.vim
A plugin to open file from file paths printed in sibling tmux pane
Stars: ✭ 50 (+177.78%)
Mutual labels:  tmux
tini
A tiny but valid `init` for containers
Stars: ✭ 7,757 (+42994.44%)
Mutual labels:  init-system
ScreenRotator
Automatic screen rotation daemon for X11
Stars: ✭ 55 (+205.56%)
Mutual labels:  screen
dotfiles
My configuration files
Stars: ✭ 24 (+33.33%)
Mutual labels:  tmux
ZFScreenRecorder
录屏,支持暂停、取消
Stars: ✭ 38 (+111.11%)
Mutual labels:  screen
dotfiles
NeoVim + git + zsh + tmux bliss
Stars: ✭ 19 (+5.56%)
Mutual labels:  tmux
onestatus
an api to customize tmux from vim
Stars: ✭ 82 (+355.56%)
Mutual labels:  tmux
joobq
JoobQ is a fast, efficient asynchronous reliable job queue and job scheduler library processing. Jobs are submitted to a job queue, where they reside until they are able to be scheduled to run in a computing environment.
Stars: ✭ 26 (+44.44%)
Mutual labels:  background-jobs

🚬 tmux-slay

This scripts allows running commands in the background, in a TMUX session.

It can be a poor man's init-sytem.

🚏 Dependencies

bash, awk, sed and tmux 🤷‍♂️

🔨 Installation

🧊 Using zinit

zinit light-mode wait lucid as"null" \
  sbin"tmux-slay" \
  atload"alias tslay=tmux-slay" \
  for @pschmitt/tmux-slay

🦆 Otherwise

Just get tmux-slay and put it in your PATH.

🎼 Completions

Completions for ZSH are available in the completions/ dir.

🎮 Usage

# Run single command
tmux-slay run COMMAND

# List running commands
tmux-slay list

# Display and follow log
tmux-slay logs -f COMMAND

# Stop/kill it
tmux-slay kill COMMAND

# Run command in a loop (repeatedly)
tmux-slay run -l COMMAND

# Run command once (don't start a second instance if it is already running)
tmux-slay run -c COMMAND

# Spawn a new instance of COMMAND and kill other windows running the same command
tmux-slay run -u COMMAND

# Clear all. Kill all running commands
tmux-slay killall

# Focus on output window running command
tmux-slay select COMMAND

⚙️ Configuration

👶 Session name

By default tmux-slay will create a new TMUX session named bg (for backgroud) to run all the commands you instruct it to.

To change that you can set the env var TMUX_SLAY_SESSION:

TMUX_SLAY_SESSION="MY_SESSION_NAME"

🌅 Init window

tmux-slay keeps its session alive by creating an empty init-window named bg-init.

To change it you need to set TMUX_SLAY_INIT_WINDOW_TITLE:

TMUX_SLAY_INIT_WINDOW_TITLE="MY_INIT_WINDOW_TITLE"

🐛 Debug mode

To debug tmux-slay just set TMUX_SLAY_DEBUG to any value:

TMUX_SLAY_DEBUG=1

🧪 Examples

💻 Run an auto-reconnecting reverse SSH tunnel to the current machine

tmux-slay run -l -c -u -n ssh-forward -- \
  ssh -o ExitOnForwardFailure=yes -R 22222:localhost:22 [email protected]
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].