#! /bin/bash Files="p8 p9 p10 p11 p12 p13 p14 p15 p16 p17" for File in $Files do #sed -i 's/abc/def/' $File sed -e 's/1/vl/g' $File | sed -e 's/2/l/g' | sed -e 's/3/n/g' | sed -e 's/4/h/g' | sed -e 's/5/vh/g' | sed -e 's/6/xh/g' > $File".policy" done