I know about minted and listings, but either of those are intended for formatting of programming languages excerpts. Is there a package that would do the same for Linux terminal excerpts?
Such as:
peter@kbpet:~$ echo $(uname -i)
x86_64
The minimal solution would be to automatically embolden the peter@kbpet: to every line and indent the leading line of each block.
The other major convenience sought is math symbols like $ and _ should be automatically interpreted as escaped.

lscolouring certain file types or permissions). – Pieter Sep 25 '11 at 09:55$bob@system:prelude to every terminal line and indent the leading line of each block. – ptrcao Sep 25 '11 at 09:59bashas language. So you should this give a try. – Thorsten Donig Sep 25 '11 at 10:01