Skip to content

Instantly share code, notes, and snippets.

@suhlig
Forked from philipsd6/install-tmux
Last active October 12, 2023 21:25
Show Gist options
  • Star 41 You must be signed in to star a gist
  • Fork 14 You must be signed in to fork a gist
  • Save suhlig/c8b8d70d33462a95d2b0307df5e40d64 to your computer and use it in GitHub Desktop.
Save suhlig/c8b8d70d33462a95d2b0307df5e40d64 to your computer and use it in GitHub Desktop.
Install tmux on rhel/centos
# Install tmux on rhel/centos 7
# What do we want?
libeventversion=2.1.11
tmuxversion=3.1
# install deps
yum install gcc kernel-devel make ncurses-devel
# DOWNLOAD SOURCES FOR LIBEVENT AND MAKE AND INSTALL
curl -OL "https://github.com/libevent/libevent/releases/download/release-$libeventversion-stable/libevent-$libeventversion-stable.tar.gz"
tar -xvzf "libevent-$libeventversion-stable.tar.gz"
cd "libevent-$libeventversion-stable"
./configure --prefix=/usr/local
make
sudo make install
cd ..
# DOWNLOAD SOURCES FOR TMUX AND MAKE AND INSTALL
curl -OL "https://github.com/tmux/tmux/releases/download/$tmuxversion/tmux-$tmuxversion.tar.gz"
tar -xvzf "tmux-$tmuxversion.tar.gz"
cd "tmux-$tmuxversion"
LDFLAGS="-L/usr/local/lib -Wl,-rpath=/usr/local/lib" ./configure --prefix=/usr/local
make
sudo make install
cd ..
# pkill tmux
# close your terminal window (flushes cached tmux executable)
# open new shell and check tmux version
tmux -V
@surebee
Copy link

surebee commented Oct 30, 2020

Awesome instructions!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment