Commit 28da9f04 authored by Aurélio A. Heckert's avatar Aurélio A. Heckert

Do not double publish pic

parent f33011aa
......@@ -176,7 +176,7 @@ echo -n '' > $imgs_json
sed -r 's#<img [^>]*src="([^"]+)"[^>]*>#\n<img src="\1">\n#ig' $slug.html |
egrep '<img src="https?://www.cienciaecultura.ufba.br/([^"]+)">' |
sed -r 's#<img src="([^"]+)">#\1#ig'
) |
) | uniq |
while read img_url; do
img_file=$( echo $img_url | sed 's#.*wp-content/uploads/##; s#/#--#g; s#[^-.a-z0-9]#x#gi' )
mime="image/$( echo $img_file | tr [A-Z] [a-z] | sed -r 's#.*\.##; s#jpg#jpeg#' )"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment