该高级Bash脚本编程指南广泛使用的例子多行注释的形式,:
echo ls -l | sh
# Passes the output of "echo ls -l" to the shell,
#+ with the same result as a simple "ls -l".
Run Code Online (Sandbox Code Playgroud)
(在管道|符号的说明中找到).其他多行注释如下所示:
#!/bin/bash
# rpm-check.sh
# Queries an rpm file for description, listing,
#+ and whether it can be installed.
# Saves output to a file.
#
# This script illustrates using a code block.
Run Code Online (Sandbox Code Playgroud)
(链接页面中的示例3.2).
什么是ratonale使用#+?一些多线评论似乎表明评论在下一行继续,但其他评论则没有.
我是否应该(尝试)遵循我自己的脚本中的"bash-scripting评论礼仪"?