1. 程式人生 > >shell-轉換字符串

shell-轉換字符串

spa zha name class pan owa file cls pre

請把下面的字符串:

zhangsan

y97JbzPru

lisi

5JhvCls6q

xiaowang

Nnr8qt2Ma

laoma

iqMtvC02y

zhaosi

9fxrb4sJD

改為如下:

zhangsan:y97JbzPru

lisi:5JhvCls6q

xiaowang:Nnr8qt2Ma

laoma:iqMtvC02y

zhaosi:9fxrb4sJD

sed N;s/\n/:/g  filename

shell-轉換字符串