Works fine here, havent needed to mock with settings to make it work like this. But the tildas scrollbar is broken by tmux, and the usual shift+pageup, and mousewheel to scroll... but thats okay.
Agree to disagree, I suppose...
How do you do reverse search, though? Any replacement for ITerm's Ctrl-F?
SO: / to search down, ? to search up. If you want to search from the top down, hit "g" in copy-mode to go to the top of the buffer (in vi mode). "G" to go to the bottom.
These, especially /, are really common conventions. / is used for search by vi, less, Opera (Firefox now too I think), even twitter.com.* My point is that / and ?, and to a lesser extent g/G/etc. soon becomes second nature and are worth learning because they are so common. How do you search backwards from the bottom in iTerm?
See "copy-mode" for more info http://www.rootr.net/man/man/tmux/1
*twitter.com (as well as duckduckgo.com and to a limited extend slashdot) uses some sweet vi keybindings. Try n, j, k, r, etc.
All terminals (GNU/Linux) Ive used tmux on, ctrl+r works, and scrolling as described in previous post.
tmux actually has a way to work around this: whenever you reattach, it looks at a whitelist of environment variables representing external resources, and either updates its own environment with the new values, or removes those settings from its environment if the place you're attaching from doesn't have them available (naturally this doesn't magically fix any processes already running inside tmux, but every new window you create will be set up correctly - unlike screen, where you have to kill every window and end the session). By defaut, this whitelist includes variables used for X11 authentication and the SSH agent. If OS X has a similar environment-variable-based connection system, you might be able to add it to tmux to get things working.
I have a wrapper script that reproduces tmux's behavior of automatically updating a set of environment variables. It goes a step further and also updates them in your running bash shells. For this to work you have to register a signal handler in your .bashrc that sources a file with the new environment. The script is available at https://github.com/sciurus/splatbang/blob/master/rescreen
https://github.com/ChrisJohnsen/tmux-MacOSX-pasteboard
The documentation recommends changing tmux's default command, but if that weirds you out, a simple alias to "reattach-to-user-namespace pbcopy" also works.
Would AppleScript do it and would that work in any application?
(As a bonus hint, binding subkeys with control it's faster to send commands: C-z C-n is faster than C-z n, you just keep control pressed during the command sequence.)
Sorry if this seems like a difficult question, but even stories of how people manage this would be great :)
Seems to work quite well, both for simple shell-like programs and full screen-oriented commands.
It does depend on a vim with Python support compiled in, but that doesn't seem like a huge constraint.
1) Open a tmux split (vertical). 2) In the left tmux pane, open vim (and split horizontally). 3) On the right side, have my tests open and running via a watch command, eg: watch -n 10 "nosetests", or something similar.
tmux users frequently tout its ability to do nifty split screens and other window management, but I'm not sure I understand the value of doing this over just starting another iterm2 window/tab and using regular window management tools. Cmd-tilde or Cmd-tab is one less key than Ctrl-a, h.... :) What am I missing?
I'm sure iterm2 does a fantastic job doing window/tab management, but I spent almost 5 years working over ssh.
edit - tmux is scriptable too, so you can setup a dev environment using a shell script (I do this, setting up my rails server, console, resque workers, etc, etc).
Mac OS X users watch out, launchctl commands barf mysteriously inside of tmux.
Then just alias launchctl to "reattach-to-user-namespace /bin/launchctl"
I have an SSH session to a remote linux server from my computer, then connect a new SSH session from my BlackBerry, and run 'tmux attach' in it.
The tmux session on the computer resizes to the size of the BlackBerry terminal, and both PuTTY and BBSSH show the same content, and both can interact with it.
Disconnect the BB, and the computer terminal resizes back to what it was.
It would seem like this would be a possibility given tmux's design, which is a lot more flexible than GNU screen's.
what i dont like about tmux: - it schokes on some weirdo programs while screen seems pretty reliable on anything
thus i end up on screen more often than not
hardstatus alwayslastline "%?%{yk}%-Lw%?%{yk}%n*%f %t%?(%u)%?%?%{yk}%+Lw%?"Monitoring background windows: with monitor-activity, monitor-silence, and monitor-content [term], you get a visual notification when there is activity, a certain period of silence, or an occurrence of [term], respectively, in a specified background window. Sometimes I open several error logs in a background window and monitor-activity so I get a notification if anything is written.
synchronize-content: I've only used this a few times but it's a neat trick! With several panes open in one window you can send keystrokes to all the panes at once. I've used this while connected to more than one server to compare the contents or make changes simultaneously. I won't claim this is the safest way to work but it comes in handy.
Managing windows and panes in tmux is pretty painless, in my experience. Resizing, switching, etc. are all very simple. One final feature I like, tho it's trivial, is the "show the time" command (bound to prefix-t). Invoking it gives you a nice big digital clock in a window or pane. I put this below my ttytter pane so I don't lose track of time. :)
I don't know how much of this you can do in screen as I've never used it, I'm sure there's a lot of overlap, but as a sometimes very critical software user let me say: I love tmux.
A neat trick: by default, C-u M-x shell opens a shell with a custom buffer name in another window (in Emacs, the different panes are called "windows") in a specified directory. If you're editing a file remotely with TRAMP, the shell will be opened remotely as well.
I find this really useful when I'm editing multiple files on multiple remote systems and need to run some commands. This also integrates well with the rest of Emacs, making working with multiple shells, different files and other stuff really easy.
So every terminal window I open already has a tmux inside and I never have that "oh, it would be nice if I haven't forgot to turn tmux on" feeling.
Inside my .vimrc:
command W :w<Bar>execute 'silent !tmux send-keys -t 1 C-r'<Bar>redraw!
This saves the buffer then sends ctr+r to pane 1 (elinks in my case), which causes a page refresh. It's very useful when debugging web scripts.http://blog.dustinkirkland.com/search/label/Byobu
You can use either a screen or tmux backend.