pike.git / lib / modules / Calendar.pmod / tzdata / zishrink.awk

version» Context lines:

pike.git/lib/modules/Calendar.pmod/tzdata/zishrink.awk:30:    return rule_name   }      # Process an input line and save it for later output.      function process_input_line(line, field, end, i, n, startdef)   {    # Remove comments, normalize spaces, and append a space to each line.    sub(/#.*/, "", line)    line = line " " -  gsub(/[[:space:]]+/, " ", line) +  gsub(/[\t ]+/, " ", line)       # Abbreviate keywords. Do not abbreviate "Link" to just "L",    # as pre-2017c zic erroneously diagnoses "Li" as ambiguous.    sub(/^Link /, "Li ", line)    sub(/^Rule /, "R ", line)    sub(/^Zone /, "Z ", line)       # SystemV rules are not needed.    if (line ~ /^R SystemV /) return   
pike.git/lib/modules/Calendar.pmod/tzdata/zishrink.awk:87:    gsub(/ Dec /, " D ", line)       # Strip leading and trailing space.    sub(/^ /, "", line)    sub(/ $/, "", line)       # Remove unnecessary trailing zero fields.    sub(/ 0+$/, "", line)       # Remove unnecessary trailing days-of-month "1". -  if (match(line, /[[:alpha:]] 1$/)) +  if (match(line, /[A-Za-z] 1$/))    line = substr(line, 1, RSTART)       # Remove unnecessary trailing " Ja" (for January).    sub(/ Ja$/, "", line)       n = split(line, field)       # Abbreviate rule names.    i = field[1] == "Z" ? 4 : field[1] == "Li" ? 0 : 2    if (i && field[i] ~ /^[^-+0-9]/) {
pike.git/lib/modules/Calendar.pmod/tzdata/zishrink.awk:137:   }      function output_saved_lines(i)   {    for (i = 0; i < nout; i++)    if (output_line[i])    print output_line[i]   }      BEGIN { +  print "# version", version    print "# This zic input file is in the public domain."   }    - /^[[:space:]]*[^#[:space:]]/ { + /^[\t ]*[^#\t ]/ {    process_input_line($0)   }      END {    output_saved_lines()   }