Simplify the ignore div-s logic - gophercgis - Collection of gopher CGI/DCGI for geomyidae
 (HTM) hg clone https://bitbucket.org/iamleot/gophercgis
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) changeset cde248e7a1d46d9c555e28ccb60513b73773ae22
 (DIR) parent 95678d96a11538682aaeed4a12d6c3ccd87a2b68
 (HTM) Author: Leonardo Taccari <iamleot@gmail.com>
       Date:   Sun, 26 Aug 2018 00:05:17 
       
       Simplify the ignore div-s logic
       
       Diffstat:
        technologyreview/article.cgi |  23 +++++++----------------
        1 files changed, 7 insertions(+), 16 deletions(-)
       ---
       diff -r 95678d96a115 -r cde248e7a1d4 technologyreview/article.cgi
       --- a/technologyreview/article.cgi      Sun Aug 26 00:02:27 2018 +0200
       +++ b/technologyreview/article.cgi      Sun Aug 26 00:05:17 2018 +0200
       @@ -8,30 +8,21 @@
        {
        
               awk '
       -       /^\<div class="article-social-list / || \
       -       /^\<div class="l-automated-trending--ordered" / {
       -               ignore = 1
       +       /<div class="article-social-list /,/<\/div>/ {
                       next
               }
       -       /^\<\/div\>/ {
       -               ignore = 0
       +       /<div class="l-automated-trending--ordered" /,/<\/div>/ {
       +               next
       +       }
       +       /<div class="callout--tagged-event-promo"/,/<\/div>/ {
                       next
               }
        
       -       /^              \<div class="callout--tagged-event-promo"/ {
       -               ignore = 1
       -               next
       -       }
       -       /^              \<\/div\>/ {
       -               ignore = 0
       -               next
       -       }
       -
       -       /^\<div class="article-enlarge__modal"\>/ {
       +       /<div class="article-enlarge__modal">/ {
                       exit 0
               }
        
       -       !ignore {
       +       {
                       print
               }
               '