Drush is the Drupal shell of choice, of course, but for some common tasks revolving around setting up test sites (including database and all), ordinary shell scripts can save a lot of time.
Here are mine.
https://gitorious.org/agaric-scripts
and mirrored to http://drupal.org/sandbox/mlncn/1110234 until one place can be identified as clearly more appropriate.