Skip navigation

Tag Archives: Unix

I was always worried about having to go up in a unix directory tree with cd ../. Then I was introduced to this project at work where I noticed that I was doing so much cd-ing around. Sometimes I went so deep in the directory tree I had this scary feeling inside that I’d get lost in a dark pit (true story).

I wanted a better way to do it. So I did what anyone these days would do. But the best the internet could offer were using pusd/popd, aliasing multiple ../s to ..n and using CDPATH. None of these felt natural enough.

So on one boring evening at work I started to scratch my own itch. I started to do it in python but I ended up in a simpler, much better solution. A function for my bashrc.

I call it za because …

cd to za

cd to za (image: markhillary flickr)

you can use za to jumpback any number of directories up to your $HOME directory. Just put the following function in your .bashrc

za 2 #will jump 2 directories up
za #will jump one directory up

Just see it in action.


za in action

Hope you find it useful.

PS: My blog marked 6 years to yesterday (8th August 2012). I’m out of (a year?) long block with this post :)

Update (07-03-2014): There’s a Fish Shell port of Za now.

You were the father of C which definitely changed the world. You created Unix with Ken Thompson and it was probably the most important piece of technology for practical computing.

some great people are great because they make their greatest contributions to the world and leave silently. You good sir will forever live in hearts of boring nerds like me.

[No picture. Because I don’t remember you from your photo. I remember you as some sort of a super power that rules a green on black world.]

Thank you for C. Thank you for Unix. Thank you for a computing environment that is comfortable for boring nerds.

Rest in peace.

Do you know what is hackers pornography? If not find the link at the end of this post. My Linux guru Ilgo sent it to me. was reading it & I found it very interesting. Nice writing style. just check it out only if you are a hacker :twisted: .

Unix Haters Handbook [The book is available for free download,just few clicks deeper from this link]