【发布时间】:2014-12-17 22:29:11
【问题描述】:
我有一个包含这一行的文件,例如:
${blue}*Passed*${NC}: check the command line ...
我可以在 bash 中读到这一行:
red='\e[41m'
blue='\e[1;34m'
purple='\e[1;31m'
NC='\e[0m' # No Color
while read line
do
echo -e $line
done < test_contest
但是输出是这样的:
${blue}通过${NC}:检查命令行...
没有颜色,bash 可以将此行解释为输出颜色吗?
【问题讨论】:
标签: bash