Thursday, March 5, 2009 easy directory navigation

A former colleague told me about which is a great little bash script that follows you around the directories you cd into and tracks how many commands were run in each directory. Then when you want to pull up the most used directory matching a certain pattern you just

j somedir

and then you end up in


and it will put you into that directory.

Much better than push, dirs combo.

Even better, you can add an additional param to qualify the first

j somedir qualifier

and then instead of


you end up in


Super Simple Web Server

I needed to serve up some images on my computer from a different port. Mongoose is a super simple webserver. So creating a webserver to some static files is as simple as

mongoose -ports 9090

and you have webserver running on port 9090 serving up the content from whatever directory you're currently in.

Just go to


and there will be your content.

It can also run cgi bins and scripts so using a scripting language and some ajax libraries so you could build yourself some simple local apps in a pinch.