PDA

View Full Version : shell script BASIC: multi line commentary



eldersoares
April 6th, 2007, 11:48 PM
thats it: how to make multi line commentaries with bash script?
thanx

WW
April 7th, 2007, 01:26 AM
What are "multi line commentaries"?

slimdog360
April 7th, 2007, 01:55 AM
I assume he is looking for the /* */ equivalent for bash. Which I wouldn't have a clue about since I know zero bash scripting.

nguyenniit1911
April 7th, 2007, 01:55 AM
I've known this way:



: <<text
Enter comments here.
text
...scripts

"text" may be any text but top and down are same.

Hope helping you!

Jucato
April 7th, 2007, 01:52 PM
I don't think there's a way to make multi-line comments in BASH. You have to put # at the beginning of each comment line.

-Rick-
April 7th, 2007, 04:20 PM
If you use a KDE editor such as Kate or KDevelop you can easily comment multiple lines by pressing ctrl+d and uncommenting by pressing ctrl+shift+d. With bash scripts it will add a '#' at the beginning of every line.