Skip to content

Commit 17f7842

Browse files
committed
Whitespace cleanup
* remove trailing whitespace * remove empty lines at the end of files
1 parent ef851f0 commit 17f7842

File tree

604 files changed

+2902
-2920
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

604 files changed

+2902
-2920
lines changed

plugins/amavis/amavis-debian

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/bin/sh
2-
#
2+
#
33
# Plugin to monitor the amavis mail filter for Debian
44
# (based upon a plugin authored by Geoffroy Desvernay)
55
#
@@ -32,7 +32,7 @@ BC=${bc:-`which bc`}
3232

3333
mktempfile () {
3434
mktemp
35-
}
35+
}
3636

3737
if [ "$1" = "autoconf" ]; then
3838
if [ -f "${AMAVIS_LOG}" -a -n "${LOGTAIL}" -a -x "${LOGTAIL}" -a -n "${BC}" -a -x "${BC}" ] ; then
@@ -96,7 +96,7 @@ then
9696
virus=`grep 'INFECTED' ${TEMP_FILE} | wc -l`
9797
spam=`grep 'Blocked SPAM' ${TEMP_FILE} | wc -l`
9898
other=`echo ${total}-${clean}-${virus}-${other}-${spam} | ${BC}`
99-
99+
100100
/bin/rm -f $TEMP_FILE
101101
fi
102102

plugins/amavis/amavis_awk

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#
33
# Plugin to monitor Amavis virus and spam statistics.
44
#
5-
#
5+
#
66
# Based on a routine by William Towle
77
# Uncomment the cdef lines to convert the graph to mails/minute
88
# Comment out the line "total.graph no" to show the total on the graph. This may not be aesthetically pleasing.
@@ -38,7 +38,7 @@ if [ "$1" = "config" ]; then
3838
echo 'graph_args --base 1000 -l 0'
3939

4040
echo 'graph_order clean p_spam b_spam virus total'
41-
41+
4242
echo 'clean.min 0'
4343
echo 'clean.type ABSOLUTE'
4444
#echo 'clean.cdef clean,60,*'
@@ -70,12 +70,12 @@ fi
7070

7171

7272
$LOGTAIL ${MAIL_LOG} $STATEFILE | \
73-
awk 'BEGIN { na= 0; nb= 0; nc= 0; nd= 0; total= 0 }
73+
awk 'BEGIN { na= 0; nb= 0; nc= 0; nd= 0; total= 0 }
74+
75+
{
7476
75-
{
76-
77-
if (index($0, "Passed CLEAN")) { na++ ; total++ }
78-
else if (index($0, "Passed SPAMMY")) { nb++ ; total++ }
77+
if (index($0, "Passed CLEAN")) { na++ ; total++ }
78+
else if (index($0, "Passed SPAMMY")) { nb++ ; total++ }
7979
else if (index($0, "Blocked SPAMMY")) { nc++ ; total++ }
8080
else if (index($0, "INFECTED")) { nd++ ; total++ }
8181
}

plugins/amule/amule_queue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
#!/bin/sh
22
#
33
# Plugin to monitor the number of clients in the the aMule queue.
4-
#
4+
#
55
# In order to use this plugin, you need to enable the "Online Signature" feature
66
# available in aMule's configuration options. You will also need to tell aMule to save
77
# the signature file in '/tmp' .
88
# For detailed instructions with screenshots, see http://linux.andreagozzi.com/content/munin_stuff.php
99
#
10-
#
10+
#
1111
# Parameters understood:
1212
#
1313
# config (required)

plugins/amule/amule_shares

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
#!/bin/sh
22
#
33
# Plugin to monitor the number of shared files with the aMule ed2k/KAD client.
4-
#
4+
#
55
# In order to use this plugin, you need to enable the "Online Signature" feature
66
# available in aMule's configuration options. You will also need to tell aMule to save
77
# the signature file in '/tmp' .
88
# For detailed instructions with screenshots, see http://linux.andreagozzi.com/content/munin_stuff.php
99
#
10-
#
10+
#
1111
# Parameters understood:
1212
#
1313
# config (required)

plugins/amule/amule_transfers

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
#!/bin/sh
22
#
33
# Plugin to monitor the UL/DL speed of the aMule ed2k/KAD client.
4-
#
4+
#
55
# In order to use this plugin, you need to enable the "Online Signature" feature
66
# available in aMule's configuration options. You will also need to tell aMule to save
77
# the signature file in '/tmp' .
88
# For detailed instructions with screenshots, see http://linux.andreagozzi.com/content/munin_stuff.php
99
#
10-
#
10+
#
1111
# Parameters understood:
1212
#
1313
# config (required)

plugins/amule/amule_uptime

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
#!/bin/sh
22
#
33
# Plugin to monitor the current aMule ed2k/KAD client uptime.
4-
#
4+
#
55
# In order to use this plugin, you need to enable the "Online Signature" feature
66
# available in aMule's configuration options. You will also need to tell aMule to save
77
# the signature file in '/tmp' .
88
# For detailed instructions with screenshots, see http://linux.andreagozzi.com/content/munin_stuff.php
99
#
10-
#
10+
#
1111
# Parameters understood:
1212
#
1313
# config (required)

plugins/apache/apache_activity

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,13 +46,13 @@ if (exists $ARGV[0] and $ARGV[0] eq "autoconf") {
4646
}
4747
my $ua = LWP::UserAgent->new(timeout => 30);
4848
my @badports;
49-
49+
5050
foreach my $port (@PORTS) {
5151
my $url = sprintf $URL, $port;
5252
my $response = $ua->request(HTTP::Request->new('GET',$url));
5353
push @badports, $port unless $response->is_success and $response->content =~ /Scoreboard/im;
5454
}
55-
55+
5656
if (@badports) {
5757
print "no (no apache server-status on ports @badports)\n";
5858
exit 1;
@@ -75,7 +75,7 @@ if (exists $ARGV[0] and $ARGV[0] eq "config") {
7575
print $val, "\n";
7676
print "activity_${port}_${char}.type GAUGE\n";
7777
}
78-
}
78+
}
7979
exit 0;
8080
}
8181

plugins/apache/apache_average_time_last_n_requests

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# Raphaël Droz <[email protected]> - 2016-01-08
44
#
55
# Monitors the average time requests matching a custom regexp takes
6-
# For instance monitor time execution of files in http://example.com/foo/bar,
6+
# For instance monitor time execution of files in http://example.com/foo/bar,
77
# requests from google, images etc.
88
#
99
# Simply add an entry in the 'type' hashref and modify the description fields
@@ -13,7 +13,7 @@
1313
#
1414
# NOTE: You need to add a field in your Apache logs showing time executed.
1515
# This is normally done using the %T (seconds) or %D (microseconds)
16-
# For instance:
16+
# For instance:
1717
# LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-agent}i\" %T %v"
1818
# Check http://httpd.apache.org/docs/2.2/mod/mod_log_config.html#formats for more info
1919
#
@@ -62,14 +62,14 @@ my $types = {
6262
# any kind of request
6363
total => {
6464
munin_fields => {
65-
label => 'All requests',
65+
label => 'All requests',
6666
draw => 'LINE2',
6767
info => 'Average seconds per any request',
6868
},
6969
sum => 0,
7070
lines => 0,
71-
matches => sub {
72-
return 1;
71+
matches => sub {
72+
return 1;
7373
},
7474
},
7575

@@ -82,11 +82,11 @@ my $types = {
8282
},
8383
sum => 0,
8484
lines => 0,
85-
matches => sub {
86-
my ($fields) = @_;
87-
my $script;
88-
($script = $fields->[6]) =~ s/\?.*\z //mx;
89-
return $script =~ m{ \.(png|jpe?g|gif|tiff|ilbm|tga) \z }mx;
85+
matches => sub {
86+
my ($fields) = @_;
87+
my $script;
88+
($script = $fields->[6]) =~ s/\?.*\z //mx;
89+
return $script =~ m{ \.(png|jpe?g|gif|tiff|ilbm|tga) \z }mx;
9090
},
9191
},
9292
};
@@ -101,7 +101,7 @@ if (@ARGV && $ARGV[0] eq 'config') {
101101
}
102102
}
103103
exit(0);
104-
}
104+
}
105105

106106
my $config_file = `ls -1 $ACCESS_LOG_PATTERN | tail -n 1`;
107107

@@ -121,13 +121,13 @@ foreach my $line (@lines) {
121121
$types->{$type}->{'lines'}++;
122122
}
123123
}
124-
}
124+
}
125125

126126
}
127127
foreach my $type (keys %{$types}) {
128128
my $value = $types->{$type}->{'lines'} ? $types->{$type}->{'sum'} / $types->{$type}->{'lines'} : 'U';
129129
printf "%s.value %s\n", ($type, $value);
130-
}
130+
}
131131

132132

133133

plugins/apache/apache_blackbox

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55
# luis peralta - [email protected]
66
# http://www.ziritione.org
77
#
8-
# Installing: configure apache blackbox and set the logfile to /var/log/blackbox.log
8+
# Installing: configure apache blackbox and set the logfile to /var/log/blackbox.log
99
# or change the BLACKBOXLOG setting below.
1010
#
11-
# Dependencies: apache mod_logio, apache blackbox
11+
# Dependencies: apache mod_logio, apache blackbox
1212
# http://www.devco.net/archives/2008/03/05/detailed_apache_stats.php
1313
#
1414
# Last version available at: http://www.ziritione.org/http_status
@@ -23,13 +23,13 @@
2323

2424
use strict;
2525

26-
my $BLACKBOXLOG = "/var/log/blackbox.log";
26+
my $BLACKBOXLOG = "/var/log/blackbox.log";
2727

28-
my %WANTED = ( "apache.status.200" => "_200",
29-
"apache.status.301" => "_301",
30-
"apache.status.302" => "_302",
31-
"apache.status.404" => "_404",
32-
"apache.status.5xx" => "_5xx",
28+
my %WANTED = ( "apache.status.200" => "_200",
29+
"apache.status.301" => "_301",
30+
"apache.status.302" => "_302",
31+
"apache.status.404" => "_404",
32+
"apache.status.5xx" => "_5xx",
3333
);
3434

3535
my $arg = shift();
@@ -78,7 +78,7 @@ graph_total total\n");
7878
);
7979
$num++;
8080
}
81-
81+
8282
}
8383

8484

plugins/apache/apache_byprojects/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22
Those plugins are used to monitor different projects or vhost (i.e. either different log files or using regular expression as filters) on the same web server.
33

44
## munin_byprojects_access
5-
Count the number of hits per projects/vhost.
5+
Count the number of hits per projects/vhost.
66
![byproject_access](https://www.mantor.org/~northox/misc/munin-plugins/nginx_byprojects_access1-month.png "byproject_access")
77

88
## munin_byprojects_bandwidth
9-
Count the total bandwidth used by each projects/vhost. [Logtail] (https://www.fourmilab.ch/webtools/logtail/) is required.
9+
Count the total bandwidth used by each projects/vhost. [Logtail] (https://www.fourmilab.ch/webtools/logtail/) is required.
1010
![byproject_bandwidth](https://www.mantor.org/~northox/misc/munin-plugins/apache_byprojects_bandwidth-month.png "byproject_bandwidth")
1111

1212
## munin_byprojects_inout_bandwidth
13-
Counts the in/out bandwidth used by each projects/vhost. [Logtail] (https://www.fourmilab.ch/webtools/logtail/) is required.
13+
Counts the in/out bandwidth used by each projects/vhost. [Logtail] (https://www.fourmilab.ch/webtools/logtail/) is required.
1414
![byproject_inout_bandwidth](https://www.mantor.org/~northox/misc/munin-plugins/apache_byprojects_inout_bandwidth-month.png "byproject_inout_bandwidth")
1515

1616
## Installation

0 commit comments

Comments
 (0)