Live data from Hacker News

My tmux setup

unwiredcouch.com

41–50 of 101 posts

Re: My tmux setup

#41
post #5
post #2

>But the years of using screen have ingrained in my muscle memory to use ctrl-a I still don't understand how this happened to so many people. Ctrl+a is already taken, how did anyone ever use screen without immediately changing it to something that doesn't conflict with a frequently used shell shortcut?

Indeed. I've been using Ctrl-\ as my Ctrl-a in screen (and occasionally tmux). Turns out that I never use that keystroke in real life.

ctrl-\ here, too.

The guy introduced me to screen recommended it. His words were "if you're an emacs guy, having this mapped to ctrl-a is going to drive you crazy"

Re: My tmux setup

#42
post #8

Earlier quoted context omitted.

The only thing ctrl-A is used for by me besides screen (or rather, tmux after I remapped it), is incrementing a number in vim. Not really a big deal.

Most people I know use it to go to the beginning of a line in programs that use readline, which includes the shell as well as most programming language interpreters.

You can set readline's editing mode to vi so that anything that uses readline will then have vi-style bindings. Very useful, particularly when combined with rlwrap for those few programs that don't have readline support.

Zsh doesn't use readline (it has it's own line editor) but it can be set to vi-style input too. (Actually, at least on my system, bash doesn't seem to be linked with libreadline.. I'm not sure if it is actually using readline or not)

Re: My tmux setup

#43
We use a combination of tmux and mumble to get multiple remote-working coders all looking at one screen. It's very useful, even if we sometimes type over each other. It's also great when somebody has to give a demo but only the guy 3 states away can really get things configured properly--just fire up a shared tmux session!

Re: My tmux setup

#44
post #28
post #2

>But the years of using screen have ingrained in my muscle memory to use ctrl-a I still don't understand how this happened to so many people. Ctrl+a is already taken, how did anyone ever use screen without immediately changing it to something that doesn't conflict with a frequently used shell shortcut?

Because ctrl-a is extremely simple, physically ... for one hand, etc. ctrl-b is fairly quick and easy if you use two hands (which is inferior to using one hand) and is quite a bit more difficult than ctrl-a when using one hand.

You appear to have invented some other post to respond to, mine said nothing about ctrl+b.

Re: My tmux setup

#46
post #2

>But the years of using screen have ingrained in my muscle memory to use ctrl-a I still don't understand how this happened to so many people. Ctrl+a is already taken, how did anyone ever use screen without immediately changing it to something that doesn't conflict with a frequently used shell shortcut?

You map CTRL+A x2 to send CTRL+A to the shell, and it works.

Yes I do sort of this, only I use CTRL+Z instead, works sweet:

  # C-z as prefix key. C-z C-z will send C-z to application, C-z z cycles last window
  set-option -g prefix C-z
  unbind C-b
  bind-key C-z send-prefix
  bind-key z last-window

Re: My tmux setup

#47

One of things I've been meaning to ask: do people who use tmux mostly run a windows machine as their desktop?

At work I use Windows->Putty->Linux->tmux, at home I use Linux->urxvt->ssh->Linux->tmux and Linux->uxrvt->tmux. When working on a Linux machine directly, I also use a tiling window manager.

Re: My tmux setup

#48
post #37

The last tip on naming windows after remote hosts is nice! Now it'd be nice if we could run similar to ssh's LocalCommand on exit too. Turned out that I'm not the first to ask this: http://unix.stackexchange.com/questions/40899/ssh-localcomma... With workaround too. The downside is that if go like ssh A then ssh B, display doesn't update. But I don't this too often anyway.

I spent a bit of time trying to figure out why it didn't work for me. Then why I couldn't even do the usual echo -e ... to change my gnome-terminal's title. Turns out I already had a PROMPT_COMMAND set to echo the last command into the title which was overwriting my changes.

Re: My tmux setup

#50
post #49

How does that email script work? Here it is: https://github.com/mrtazz/bin/blob/master/imap_check.py This looks for a file at ~/.netrc What is the format of that file? Google results can't find this being used for email anywhere.

Mine looks like:

  machine smtp_server.company.com
          login user.name@company.com
          password supersecret
Post reply on HN