Boost your console productivity on tmux

With “ Oh My Tmux!”, a self-contained, pretty and versatile tmux configuration file

tmux is a tool that can be used to multiplex several virtual consoles, allowing a user to access multiple separate terminal sessions inside a single terminal window or remote terminal session.

It lets you switch easily between several programs in one terminal, detach them (they keep running in the background) and reattach them to a different terminal.

The commands are pretty simple to memorize, but if you need a quick reference, you can use this cheat sheet:

<a href="https://medium.com/media/bff0e9a67378076277c26849bcb8dc7c/href">https://medium.com/media/bff0e9a67378076277c26849bcb8dc7c/href</a>

However, tmux may be very useful only if properly configured.

Regarding that, I want to share “Oh My Tmux!”, a configuration file edited by Gregory Pakosz, which expands the possibilities of tmux in a remarkable way.

Features

  • C-a acts as secondary prefix, while keeping default C-b prefix
  • visual theme inspired by Powerline
  • maximize any pane to a new window with <prefix> +
  • SSH aware username and hostname status line information
  • mouse mode toggle with <prefix> m
  • automatic usage of reattach-to-user-namespace if available
  • laptop battery status line information
  • uptime status line information
  • optional highlight of focused pane (tmux >= 2.1)
  • configurable new windows and panes behavior (optionally retain current path)
  • SSH aware split pane (reconnects to remote server, experimental)
  • copy to OS clipboard (needs reattach-to-user-namespace on macOS, xsel or xclip on Linux)
  • Facebook PathPicker integration if available
  • Urlview integration if available

Installation

Requirements:

  • tmux >= 2.1 running inside Linux, Mac, OpenBSD, Cygwin or WSL (Bash on Ubuntu on Windows)
  • outside of tmux, $TERM must be set to xterm-256color

To install, run the following from your terminal: (you may want to backup your existing ~/.tmux.conf first)

$ cd
$ git clone https://github.com/gpakosz/.tmux.git
$ ln -s -f .tmux/.tmux.conf
$ cp .tmux/.tmux.conf.local .

Then proceed to customize your ~/.tmux.conf.local copy.

More information and downloads

Boost your console productivity on tmux was originally published in So Long, and Thanks for All the Fish on Medium, where people are continuing the conversation by highlighting and responding to this story.

Article Link: https://andreafortuna.org/boost-your-console-productivity-on-tmux-f0029c7adcf2?source=rss----bf18ac17f001---4