nix/modules/home-manager/scripts/common/bin/tmux-save-buffer
2023-10-05 13:43:28 -05:00

9 lines
197 B
Bash
Executable file

#!/usr/bin/env sh
d="$(date +%Y-%m-%d_%H-%M-%S)"
f="${USER_LOGS_PATH}/${d}.tmux-buffer.log"
mkdir -p "$(dirname "$f")"
touch "$f"
chmod 600 "$f"
tmux capture-pane -pS -1000000000 > "$f"
echo "$f"