Guest User

Untitled

a guest
Apr 24th, 2018
210
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. s/cid:image002.gif@01CC3D46.926E77E0/https://mysite.com/files/1922/g
  2. s/cid:image003.gif@01CC3D46.926E77E0/https://mysite.com/files/1923/g
  3. s/cid:image004.jpg@01CC3D46.926E77E0/https://mysite.com/files/1924/g
  4.  
  5. while read cid fileid
  6. do
  7. cidpat="$(echo $cid | sed -e s/\./\\./g)"
  8. echo 's/'"$cidpat"'/https://mysite.com/files/'"$fileid"'/g' >> sedscr
  9. done
  10.  
  11. escaped_lhs=$(printf '%sn' "$lhs" | sed 's:[][/.^$*]:\&:g')
  12. escaped_rhs=$(printf '%sn' "$rhs" | sed 's:[/&]:\&:g;$!s/$/\/')
  13.  
  14. sed "s/$escaped_lhs/$escaped_rhs/"
  15.  
  16. A=lhs B=rhs perl -pe 's/Q$ENV{A}E/$ENV{B}/g'
Add Comment
Please, Sign In to add comment