多重叠加:
grep -n 'faceGo' $rc | awk -F ":" '{print $1}'|xargs -I {} echo -e "-e {}d"|xargs|xargs -I {} echo sed -i -e {} $rc |sh
IP正则:
cat Service.Config.xml|tail -n 6 |grep -o -e '[0-9]\{1,3\}.[0-9]\{1,3\}.[0-9]\{1,3\}.[0-9]\{1,3\}' |awk '{print$1}'
ip a show dev team0 | grep inet | grep brd | grep -o -e '[0-9]\{1,3\}.[0-9]\{1,3\}.[0-9]\{1,3\}.[0-9]\{1,3\}' | sed -n "1p"
网友评论