File: specmiss

package info (click to toggle)
postfix 2.3.8-2%2Betch1
  • links: PTS
  • area: main
  • in suites: etch
  • size: 15,744 kB
  • ctags: 11,426
  • sloc: ansic: 81,810; makefile: 10,743; sh: 7,874; perl: 2,468; awk: 41
file content (27 lines) | stat: -rwxr-xr-x 520 bytes parent folder | download | duplicates (16)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/usr/bin/perl

# Get all the postconf parameter names from the postconf.proto file.

die "Usage: $0 protofile [filename...]\n" 
        unless $protofile = shift(@ARGV);

# Read the whole file even if we want to print only one parameter.

open(POSTCONF, $protofile) || die " cannot open $protofile: $!\n";

while(<POSTCONF>) {
   if (/^%(PARAM)\s+(\S+)/) {
	$found{$2} = 1;
   }
}

while (<>) {
    if (/^%(PARAM)\s+(\S+)/) {
        delete $found{$2};
    }
}

for $name (sort keys %found) {
    print $name,"\n";
}