Gah !
# !$ references the last argument of the previous command.
mate _posts/2011/2011-04-12-terminal-strings.mdown
git add !$
tumblr !$
# Now more complex, let's copy the second argument
# !! references the last command, and :2 the second arg.
echo foo bar baz
echo !!:2 # outputs "bar"
# Batshit crazy
# !?baz? references the last command containing baz, :0-1 grabs the two first args
echo !?baz?:0-1 # should output "echo foo"