Consultancy - Research Lab - Incubator

based in beautiful Zürich, Switzerland

- 102 words - 1 min read

I'm using the command line extensively, with plenty of black terminals side by side in my tiling window manager I was looking for something that helps distinguish remote shells (via ssh) from my local shells.

Introducing one of my favorite tricks: Changing the background color of the terminal while running an ssh session.

function ssh() {
  dbus-send --session /net/sf/roxterm/Options net.sf.roxterm.Options.SetColourScheme string:$ROXTERM_ID string:Tango
  /usr/bin/ssh $@
  dbus-send --session /net/sf/roxterm/Options net.sf.roxterm.Options.SetColourScheme string:$ROXTERM_ID string:Default

In my setup I'm using zsh and roxterm, but I'm sure it'll work for other tools as well if you adjust it to yours.


- 362 words - 2 min read

Back in the days when I was developing in Ruby most of my waking hours rbenv was a real life saver. But looking at what it does, it initially felt awkward how it "wrapped" the cd command. You could argue that the Ruby community are no strangers to guerrilla patching. But it felt less awkward when I learned that in my zsh it uses hooks instead of guerrilla patching to achieve the same goal: React on changing the directory.

In the meantime I tried a couple of things with zsh hooks to optimize work flows and what not, but...