Syntax highlighting

I’ve been writing a text document, where I want to paste an excerpt of a shell script. I want to put it in a frame as a separate “figure”, referred to in the text as “Box ##”. To make it clearer to the reader, I want to have the appropriate syntax highlighting. How to do it?
Read the rest of this entry »