http://linux.byexamples.com/archives/279/record-the-terminal-session-and-replay-later/ is a page explaining the use of script and scriptreplay in order to record a bash session and play it again. I really find this very useful, though I do not really use it very often. But perhaps using this tutorial, I will manage to use it.