#!/usr/bin/perl require("./poplib.pl"); # &grabmail("username","password","server","deliverto"); # file: username,password,server,deliverto # ./processmail to run, ./processmail 1 to run debug # - Presence if ($ARGV[0]) { $debug = 1; } while (1 == 1) { open (EMAILLIST,"./emailstocheck.csv"); while () { next if ($_ =~ /^\#/); next if ($_ =~ /^$/); chomp $_; @linearray = split(",",$_); print "+ checking ". $linearray[0] ."...\n" if ($debug); &grabmail($linearray[0],$linearray[1],$linearray[2],$linearray[3],$debug); } sleep(180); # 3 mins }