7

Moving from OS X, loving Ubuntu so far.

One thing I'm missing is an iTerm 2 like terminal emulator that allows for easy screen splitting. I could use tmux, but would like to be able to copy and paste between terminal windows and applications easily...which tends to be difficult in tmux.

Any suggestions?

1
  • 1
    One way to do it within the confines of tmux is to use box-selection with [ctrl]+[shift]+mouse, but that's not really optimal I think.
    – arand
    Nov 9, 2012 at 22:39

5 Answers 5

11

I think you may want the other terminator Install terminator actually ;)

There's http://software.jessies.org/terminator/ (gokcehan's answer) and https://launchpad.net/terminator (install link above).

Which appears to be different projects, with a very similar purpose, confusingly enough. I think the one hosted on launchpad one is the one you want for your purpose though, and it's readily available in the Ubuntu Software Centre.

5

You can do it in screen the terminal multiplexer.

  • To split vertically: ctrla then |.
  • To split horizontally: ctrla then S (uppercase one).
  • To unsplit: ctrla then Q (uppercase one).
  • To switch from one to the other: ctrla then tab

EDIT, basic screen usage:

  • New terminal: ctrla then c.
  • Next terminal: ctrla then space.
  • Previous terminal: ctrla then backspace.
  • N'th terminal ctrla then [n]. (works for n∈{0,1…9})
  • Switch between terminals using list: ctrla then " (useful when more than 10 terminals)
  • Send ctrla to the underlying terminal ctrla then a.

You can also try dvtm+dtach:

http://www.brain-dump.org/projects/dvtm/

Here is an article comparing them: http://chithanh.blogspot.com/2010/07/three-way-mini-shootout-between-gnu.html

2
  • 1
    Thanks @cprofitt. The main issue for me is GUI copy+paste, which are problematic in screen/tmux emulators. What generally happens is I select a piece of text in one window, and if it's longer than one line, it ends up pulling text from the window to the right of it as well. In iTerm this isn't an issue, because each window is (apparently) a whole different instance of terminal, so copy+paste, scrollback buffers etc are all isolated. Anything similar in Ubuntu? Oct 12, 2012 at 14:02
  • Could you just use the tab feature of the standard gnome terminal?
    – cprofitt
    Oct 13, 2012 at 23:37
2

I think you want the terminator.

1

Personally I'm finding that tmux+UXTerm gives me all the tmux-style screen splitting that I need. I can also "copy and paste between terminal windows and applications easily" - well, fairly easily, anyway.

To paste from the X clipboard, I need to remember to use shift+insert

To copy to the X clipboard, hold down shift while selecting the text to copy, then left-click when done. To paste that into another app, use shift+insert in the other app.

There's one area where this doesn't work perfectly: if I've got a vertical split and want to copy multiple lines. uxterm doesn't understand the split. To get around this I have "bind-key z resize-pane -Z" in my .tmux.conf; this toggles the pane between normal size and "zoomed" mode, where it occupies the whole window. C-b z makes it big, then I can copy, C-b z pops it back to normal size in the layout.

1

I'm using xsel as my clipboard manager (it's in ubuntu package manager) and tmux as my terminal multiplexer and to copy to and from the two is as simple as pressing the bind key + < (to copy to tmux) and bind key + > to copy to xsel.

In my tmux.conf file i have these lines,

  • To copy to tmux from xsel.

    bind-key < command-prompt -p "copy to tmux (hit enter to confirm):" "run-shell 'tmux set-buffer -- \"$(xsel -o -b)\"'"
    
  • To copy to xsel from tmux.

    bind-key > command-prompt -p "copy to xsel (hit enter to confirm):" "run-shell 'tmux show-buffer | xsel -i -b'"
    

It's that easy really.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .