/[cvs]/gateway/.dispatchmailrc
ViewVC logotype

Contents of /gateway/.dispatchmailrc

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations)
Fri Jan 24 19:42:35 2003 UTC (21 years, 3 months ago) by gateway
Branch: MAIN
initial check-in

1 package rules;
2
3 use strict;
4 # don't use warnings;
5
6
7 my $mc = 0;
8 sub mark {
9 $mc++;
10 #report("mark $mc");
11 }
12
13 sub dispatch {
14
15 my $self = shift;
16
17 my $incoming = $self->{incoming};
18 my $MAILDIR = $self->{settings}->{MAILDIR};
19
20 my $from = $incoming->from;
21 my $to = $incoming->to;
22 my $subject = $incoming->subject;
23
24 chomp($from);
25 chomp($to);
26 chomp($subject);
27
28 # -----
29 # target-based-routing (gateway to news in this case...)
30 print "to: $to", "\n";
31 if ($to =~ /links-computing/) {
32 print "COPY", "\n";
33 #$self->copy('Newsgate', 'alt.test');
34 $self->copy('Newsgate', 'nfo.links.computing');
35 #my $prg = $0;
36 #my $prg = '/data/opt/dispatchmail/bin/dispatchmail';
37 #my $prg = '/etc/mail/smrsh/dispatchmail';
38 #my $pipeTo = $prg . ' --mode=mail2news --thread=alt.test --base=/home/collector';
39 #$self->report("PIPE: " . $pipeTo);
40 #$incoming->pipe($pipeTo);
41 }
42
43 $self->ignore();
44 #$self->accept("$MAILDIR/Inbox");
45
46 }
47
48 1;

MailToCvsAdmin">MailToCvsAdmin
ViewVC Help
Powered by ViewVC 1.1.26 RSS 2.0 feed