上下两行变为一行
#!/bin/bash
# 将奇数行的换行符替换为空格
count=1
cat token | while read line
do
if [ `expr ${count} % 2` -eq 0 ];then
echo ${line}|awk -F: '{print $2}'|tr -d '"}'
else
echo ${line}|awk '{print $1}'|tr "\n" " "
fi
let count++
done
阅读(497) | 评论(0) | 转发(0) |