Well, that's not a very perl way to do it.
It's probably the solution I'm going to use though.
Had I know that option existed, I would not have asked the question.
I thought I had looked everywhere for such a switch, where
on earth did you find it?
update: -interaction=nonstopmode ... is cool, but I have
basically the same problems! I don't understand why I'm
having so much trouble just cuz I'm calling this from
a CGI. I even did a 'su - nobody' and executed the commands
as they appear in the CGI (everything was keen when I typed
it by hand) :{.
another update: This problem is solved. I did use -interactive=nonstopmode, but get this:
while(<T>) {
if(m/[{]ONF ([^}]+)[}]/) {
my $v = $1;
my $sv = shift @ONFs;
push @ONFs, $v if $sv =~ /ding/;
s/ONF/$sv/;
}
s/NAME/$fields{name}/;
print U "$_";
}
#close T, U; # wasn't closing U in time!
close T;
close U;
`(
cd $dir; [ -f $tname.tex ] && latex --interaction=nonstopmode $
+tname.tex 2>/dev/null
[ -f $tname.dvi ] && dvips -f $tname.dvi
[ -f $tname.ps ] && lpr $tname.ps
)`
When I tried to close both T and U at the same time,
the tex file wasn't fully written by the time I got
to the shell fork. wtf?
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.