Projet

Général

Profil

Révision b26ba8e6

IDb26ba8e6bd65d67aa23cce32e8dd9d5c6d9d12b7
Parent 19a3cbe3
Enfant ac1af8bd

Ajouté par Kael Shipman il y a environ 7 ans

Bugfix and re-positioning

Voir les différences:

plugins/logs/loggrepx_
100 100
    while read -u 3 -r logfile; do
101 101
        var_prefix="$(echo "$logfile" | sed -r 's/^[^a-zA-Z]+//g' | sed -r 's/[^a-zA-Z0-9]+/_/g')"
102 102
        var="${var_prefix}_label"
103
        lbl="${!var:-0}"
104
        echo "$var_prefix.label $([ -n "$lbl" ] && echo "$lbl" || echo "$logfile")"
103
        lbl="${!var:-$logfile}"
104
        echo "$var_prefix.label $lbl"
105 105
        print_warning "$var_prefix"
106 106
        print_critical "$var_prefix"
107 107
        echo "$var_prefix.info Lines that match '${regex}' in log file '$logfile'"

Formats disponibles : Unified diff