Skip to content

r6eve/tmux-tanlog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

tmux-tanlog

Build Status

tmux-tanlog is a tmux/zsh version of tanlog (It's original GNU Screen version).

This tool saves console outputs into text files in /tmp/tanlog/. It depends on tmux and zsh.

Installation

From source codes

$ git clone https://github.com/r6eve/tmux-tanlog.git
$ cd tmux-tanlog
$ cargo install --path .

From executable binaries

See Releases. tmux-tanlog-${version}-x86_64-unknown-linux-musl is statically linked binary.

Arch Linux

yay -S tmux-tanlog-bin

Settings

And add the following to your .zshrc

tanlog_begin() { export TANLOG_LOGFILE=$(tmux-tanlog start "$1") }
tanlog_end() { tmux-tanlog end $TANLOG_LOGFILE }
typeset -Uga preexec_functions
typeset -Uga precmd_functions
preexec_functions+=tanlog_begin
precmd_functions+=tanlog_end

Output directory defaults to /tmp/tanlog. Set the environment variable TANLOG_DIR if you want to change it.