This is a website by Willem van Zyl

I'm a project manager, software developer, Apple evangelist and geek from South Africa. I'm passionate about web and mobile application development, usability, productivity, physics, astronomy, science fiction and fantasy.

If you would like to contact me, message me on Twitter or send me an email.

How to reuse the last specified parameter on the command line

03 Jun 2009

If you want to reuse the last parameter you specified for a command in a Bash shell, you can use the "!$" tag.

An example of where this would be useful is if you create a directory with a long path, then want to switch to it:

mkdir /home/willem/some_folder/another_folder/new_folder
cd !$
Do you like this? Share it:

Copyright © Geekology 2011. All Rights Reserved.

Hosted by Code. Like. Clockwork.