How can I reattach to tmux process

You can not re-attach a process id. You need to reattach the corresponding tmux session. So do tmux ls. Pick whatever session you want to re-attach. Then do tmux attach -d -t <session id> to re-attach it to a new tmux instance and release it from the old one.

List running Jupyter notebooks and tokens

UPDATE You can now just run jupyter notebook list in the terminal to get the running jupyter sessions with tokens. Take care that you are within the right environment (conda, virtualenv etc.) otherwise the sessions will list without the associated tokens. Eg: The above reference screenshot is from the conda environment. Old answer: Run ipython … Read more

How to copy to system clipboard from tmux output after mouse selection?

If you are using iTerm2, you can copy text in Tmux session, holding down the Option key while dragging the mouse to make selection. Then it should be possible to paste text anywhere with Cmd + V as usual. Found it here: http://web.archive.org/web/20131226003700/http://ootput.wordpress.com/2013/08/02/copy-and-paste-in-tmux-with-mouse/

Move window between tmux clients

Yes, you can use the move-window command: move-window [-d] [-s src-window] [-t dst-window] (alias: movew) This is similar to link-window, except the window at src-window is moved to dst-window. where src-window and dst-window have the form: session:window.pane (session and window can be either name or id). So, supposing you have an ‘chat’ session with an … Read more

Pane Title in Tmux

This functionality has been added to tmux in this commit. It is not in version 2.2, but it looks like it will be in 2.3. To enable it: tmux set -g pane-border-status top or if you prefer: tmux set -g pane-border-status bottom To set a custom text as your pane border status line you can … Read more

Tmux vs. iTerm2 split panes

There is another advantage of tmux: what happens if you accidentally close iterm2? If you do it really by accident, you want to reopen everything again. With tmux it is normally as simple as reattaching session without losing anything. Most terminal emulators send SIGHUP to all children which terminates them by default and thus you … Read more