Correct error for comment on set -e, and write it more descriptively
Add temporary directory creation and clean-up