Revamp buffer handling; improve tmux integration