09 October 2014

Tags: bash | shell |

blog_post_image_inline

What is the simplest way to define block comment in Bash script?

I’ve selected two approaches for myself:

#!/usr/bin/env bash

echo "before block comment"
: <<'END'
Some long 
myltiline 
text
END
echo "after block comment"
#!/usr/bin/env bash

echo "before block comment"
if [ ]; then 
Some long 
myltiline 
text
fi
echo "after block comment"


comments powered by Disqus