Possible Duplicate:
Bash: How to Put Line Comment for a Multi-line Command
I would like to do something like this
sudo apt-get install \
#a very long description
#of the package
#that spans multiple lines
pkg1 \ #maybe I want an inline comment also
#another description that
#spans multiple lines
pkg2
Note that I’m not just interested in the apt-get command.
As far as I know Bash ignores everything after the ‘#’ in a single command, and multilining won’t change that. However you can probably achieve the same level of expression using bash arrays: