shell去掉输出的末尾换行符
用echo -n $(you_command)即可。
比如:
echo -n $(echo test)
输出:
[searchstar@localhost ~]$ echo -n $(echo test)
test[searchstar@localhost ~]$
用echo -n $(you_command)即可。
比如:
echo -n $(echo test)
输出:
[searchstar@localhost ~]$ echo -n $(echo test)
test[searchstar@localhost ~]$