Sunday 29 May 2011
-
Filed under
Uncategorized
::
Share or discuss
::
2011-05-29 ::
mattr
Sunday 22 May 2011
-
Filed under
Uncategorized
::
Share or discuss
::
2011-05-22 ::
mattr
Sunday 1 May 2011
-
Filed under
Uncategorized
::
Share or discuss
::
2011-05-01 ::
mattr
Sunday 24 April 2011
-
Filed under
Uncategorized
::
Share or discuss
::
2011-04-24 ::
mattr
Sunday 17 April 2011
-
Filed under
Uncategorized
::
Share or discuss
::
2011-04-17 ::
mattr
Sunday 10 April 2011
-
Filed under
Recommended Stuff
I’ve been using GNU screen for years now as a way to deal with all the terminals I need to use at once (terminal multiplexing is what I talk to my wife about when I know she doesn’t want to hear about work). I started out using it, as many do, because I needed to do some work over ssh on a remote terminal, and losing that connection was painful without using screen. After getting used to it, I found I liked using it even when I wasn’t working over ssh because it gave me a way to easily manage a bunch of terminal sessions.
Then one day I wanted to do remote pairing and had heard of people doing this in screen. It’s a bit of a pain to setup with screen (shared login or chmod to set uid bit), but then I discovered tmux – and realized how many things screen didn’t have that I now don’t want to live without. The main thing being vertical splits. I used to think vertical splits were just for vim sessions, but I was wrong. The tmux faq has a much fuller list of differences from screen that are nice (auto naming windows, more intuitive help, easier multiuser, multiple sessions). In tmux vs screen tmux wins hands down. The only things I’ve found I miss about screen is that my vim sessions were part of the scrollback buffer, but in tmux they disappear from tmux’s scrollback when you exit vim.

Why not iTerm2, Terminator for Gnone, other OS specific terminal app here? Did I mention they’re OS specific? I want a terminal solution that works on any terminal the same way, and over ssh connections. Oh, and open source and BSD licensed is nice too even if I never look at the source code.
::
Share or discuss
::
2011-04-10 ::
mattr
Sunday 10 April 2011
-
Filed under
Uncategorized
::
Share or discuss
::
2011-04-10 ::
mattr
Wednesday 6 April 2011
-
Filed under
Recommended Stuff + Tips and Tricks
I’ve been meaning to write this post forever, but once I started doing what I suggest here it seemed so obvious that I have trouble remembering what life was like before I did it. Once you’ve been working in a terminal for long enough, you realize how much more productive you can be with your aliases, scripts, prompts, plugins and other configurations setup the way you like. This becomes especially apparent when you either work on someone else’s machine, or something happens and you have to rebuild yours and you realize just how slow you are in comparison.
How do you avoid this slowdown and prevent loss of all those great hacks and configurations you’ve built up? Version control all the files that enable your productive environment. Here’s my repo for all those files.
https://github.com/mmrobins/config-files
I’ve got bash, zsh, vim, screen, tmux, irb, tmux, irssi, ruby scripts, puppet scripts and more in this git repository. I spend a lot time working remotely via ssh or on virtual machines on my development box, so it’s important not only that I have these files available, but I also have a fast way to get all these files in place quickly. I also want changes that I make to these files to be easy to commit back to my repository. To accomplish this, I make all these files symlinks to the files in my repository so that if I edit ~/.bashrc with my great new alias that saves all sorts of typing, it’s actually editing the .bashrc in my git respository. Then I have a little perl script that when run puts all these symlinks in place for my automatically and backup up any files I’m moving out of the way to create the links, just in case.
https://github.com/mmrobins/config-files/blob/master/create_symlinks
Now whenever I end up in a new environment on the terminal, I can get all my productivity in place with a few simple commands from the home directory.
git clone git://github.com/mmrobins/config-files.git
./config-files/create_symlinks
source .bashrc
Now vim has my plugins and configuration, bash has my prompt, if GNU Screen or tmux are available they’re how I like them, my aliases work, etc. There’s always going to be tweaks necessary for this to work cross platform and on different machines with different privileges, but since committing those changes back to the git repo is so easy, it become a natural part of my workflow to have these incremental improvements to my work environment available everywhere I work.
2 comments ::
Share or discuss
::
2011-04-06 ::
mattr
Sunday 3 April 2011
-
Filed under
Uncategorized
::
Share or discuss
::
2011-04-03 ::
mattr
Monday 4 October 2010
-
Filed under
Uncategorized
::
Share or discuss
::
2010-10-04 ::
mattr