#perl - Thu 15 Mar 2007 between 20:13 and 20:37



_stuufgah why do i have an _ ?
crungeI'm writing an auditing script and I'd like it so that if it's run from a shell by a person it prints its report to STDOUT
if not, it mails the report to a contact address
maukeew
crungeand now that I say that "out loud" I realize how stupid it is
Woostacrunge: use a command line option
crungeand that I should just make the cron job pipe to mail
BradipoOk, the BEGIN block seemed to work.
WoostaThen in your cron: myScript.pl --mail
or yes, pipe it to mail from cron :)
Bradipo: don't mess with @INC .. use lib
crungeI apologize for my stupid moment. I emptied my smart buffer writing the script :)
BradipoWoosta: What do you mean?
WoostaBradipo: as in: use lib '/path/to/lib';
BradipoSo like: use Module::Name '/path/to/lib';
WoostaNO
Bradipolib is a keyword?
Woostause lib '/path/to/lib'; use Module::Name;
BradipoAhh.
I see.
rhizouse lib q{/path/to/lib}; use Module::Name;
crungewow... 18K queries in 30 sec on this caching DNS
BradipoThanks for the help, its loading the correct module now.
Limbic_Regionsomeone ask an interesting question - I'm bored
LeoNerdHow should I handle SIGCHLD?
Limbic_Regionwith firm, but loving hands
LeoNerdwaitpid( -1, WNOHANG ) and see what I get..?
Or, waidpid( $pid, WNOHANG ) on each of the child processes I'm waiting on
Limbic_RegionLeoNerd - presumably you need to wait for them all but there is useful work you could be doing while you wait
?
LeoNerdSee WNOHANG
Namely, I know at least one child died...
Do I iterate the child process IDs I'm looking for, to see which, or do I go for -1 to just see what pops out..?
Limbic_Regionperhaps you explained more of what you were doing earlier and I missed it (as I just joined)
I don't know what you are trying to accomplish in the first place
so it is rather difficult to propose a solution if the desired behavior is unknown
LeoNerdI was mainly trying to supply an interesting question :)
xbansheexUpdating has not helped.
Limbic_Regionoh
well

Page: 5 12 19 26 33 40 47 54 61 68 75 82 89 

IrcArchive