Left: | ||
Right: |
OLD | NEW |
---|---|
(Empty) | |
1 #!/bin/sh | |
2 | |
3 # Filter out uninformative output lines from the ldap-sync cron job script | |
4 | |
5 last_action="" | |
6 last_updated="" | |
7 | |
8 while read line; do | |
9 case "$line" in | |
10 *Updating*|*Creating*) | |
11 last_updated="$line" | |
12 ;; | |
13 *-\>*) | |
14 case "$last_action" in | |
15 *-\>*) | |
16 echo "$line" | |
17 continue | |
18 ;; | |
19 esac | |
20 echo "$last_updated" | |
21 echo "$line" | |
22 ;; | |
23 *Found* | \ | |
24 *\#* | \ | |
25 *Synchronizing*) | |
26 continue | |
27 ;; | |
28 *) | |
29 echo "$line" | |
30 ;; | |
31 esac | |
32 | |
33 last_action="$line" | |
34 done | |
OLD | NEW |