To save my tmux buffers in separated text files I have used this
one-liner... maybe it will be useful to someone.

for buf_name in `tmux list-buffers | sed -e 's/\(buffer[0-9]*\).*/\1/'`; do
echo "**buffer: $buf_name"; tmux save-buffer -b $buf_name "$buf_name.txt";
done

I suppose that for restore it will be something similar, but with
"tmux load-buffer".

Cheers,
Darek

2016-07-22 10:27 GMT+02:00 Dariusz Dalecki <[email protected]>:

> Hi,
>
> Is there a way to "save to"/"restore from" file a tmux copy-buffer?
>
> From time to time, I have useful "savings" in copy-buffer like "bash one
> liner's" to perform some command on bunch of files and I would like to save
> it in a file for a longer time without doing extra commands like: opening
> vim, paste buffer and save it in a new file...
>
> Thanks for help,
> Darek
>

-- 
You received this message because you are subscribed to the Google Groups 
"tmux-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send an email to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to