shell gbk转utf8

iconv -f GB18030 -t UTF-8 0101.html

去除文章中的换行:

tr -d “\n”

for循环多行数据

<code>    IFS=$'\n'
    for line in $list
    do
       echo "line:$line"
    done</code>


<code>     </code>


发表评论?

0 条评论。

发表评论


注意 - 你可以用以下 HTML tags and attributes:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>