Just a question to improve my bash skills. I always do this:
bash
$ history | grep some_long_command ... ... 123 some_long_command1......... 124 some_l
^p to get the last typed command in unix/solaris