Re: How to make a resource intensive script less intensive.

2001-07-08 Thread Sandor W. Sklar
)
 ($timestart,
  $timestop) = get_seconds();
  print Timestart is: $timestart and  .
timestop is: $timestop\n;
 }

 }

 }
 seek(QLOG, $curpos, 0);
 }
}





- Jim

-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
http://www.perlmonks.org/index.pl?node_id=67861lastnode_id=67861

-BEGIN PERL GEEK CODE BLOCK-  --BEGIN GEEK CODE BLOCK--
Version: 0.01 Version: 3.12
P++*@$c?P6?R+++@$M  GIT/CM/J d++(--) s++:++ a-
$O!MA-E! PU--+++BDC(+) UB$L$S$
$C-@D!(-)$S@$X?WP+MO!+++   P++(+)+ L+++()+$ !E*
+PP+++n-CO?PO!o G   W++(+++) N+ o !K w--- PS---(-)@ PE
*(!)$A--@$Ee---(-)Ev++uL++*@$uB+   Y PGP t+(+++)+++@ 5- X++ R@
*@$uS+*@$uH+uo+w-@$m!   tv+ b? DI-(+++) D+++(++) G()
--END PERL GEEK CODE BLOCK--  --END GEEK CODE BLOCK--


-- 

sandor w. sklar|Non impediti
unix systems administrator | ratione
stanford university itss-css   |cogitationis




Re: Accessing printer functions

2001-06-07 Thread Sandor W. Sklar


On Thu, 7 Jun 2001, Clive Lansink wrote:

   I need to write a Perl application that must produce some printed
  information which requires both portrait and landscape printing at the same
  time, with lines and boxes.  This is for a Windows 98 system.  I've been
  pondering on how best to do this and have the following questions:

  [...]

  *  What is the simplest way nowadays to program an application to have good
  printer control and to produce reports etc with a variety of fonts, lines
   and boxes etc.


I can't speak to doing this on a windows system, but on unix, I've 
done something similar by creating passing an arrray to enscript 
containing the escape codes and text that I want, and telling 
enscript to print to standard out, storing that in another array, 
which I then send to the printer later in the script.

I can send you my script for reference, if it will help, but I don't 
know if enscript is available for windows, and I have no idea how to 
do the same thing with PCL.

--Sandy
-- 
sandor w. sklar
unix systems administrator 
stanford university itss-css



Re: Installing Perl on AIX platform

2001-06-01 Thread Sandor W. Sklar

it sounds like your download was incomplete.  You may want to try 
downloading it again.

FYI, AIX 4.3.3 comes with perl; other binary distributions are 
available from various places.

-s-

At 3:11 PM -0400 6/1/01, Swappan Das wrote:
Please some body help me .

I download the latest Unix version from CPAN  then I followed as:

gzip -dc latest.tar.gz | tar xvf -

output from the above command:
x perl-5.6.1
x perl-5.6.1/AUTHORS, 27914 bytes, 55 media blocks.
x perl-5.6.1/Artistic, 6111 bytes, 12 media blocks.
x perl-5.6.1/Changes, 1779374 bytes, 3476 media blocks.

Then I did cd perl-5.6.1

I found only three files:
-r--r--r--   1 504  50427914 Apr  8 02:09 AUTHORS
-r--r--r--   1 504  504 6111 Feb 22 21:57 Artistic
-r--r--r--   1 504  504  1779374 Apr  8 23:11 Changes

At this point I am lost what should I do

I tried to run the command and it fails:
sh configure c

I tried to look for AIX README files on CPAN, I could not find it.

If somebody installed successfully on AIX 4.3.2,  please help me.

Thanks in advance,



Swapan Das
Database administrator
LifeBridge Health
410-601-9898
[EMAIL PROTECTED]


-- 
sandor w. sklar
unix systems administrator 
stanford university itss-css



pulling out part of a /path/to/a/file

2001-04-24 Thread Sandor W. Sklar

Hi, folks ...

I'm generating a list of files (from a find subroutine) and putting 
them in an array.  The list looks like ...

/home4/dsadmin/7790/DocuShare/documents/b003/File-11523.1
/home4/dsadmin/7790/DocuShare/documents/b003/File-11587.1
/home4/dsadmin/7790/DocuShare/documents/b003/File-11651.1
/home4/dsadmin/7790/DocuShare/documents/b004/File-1156/html/main.htm
/home4/dsadmin/7790/DocuShare/documents/b004/File-1604/html/main.htm

(... a small sample)

and I'm trying to get just the File- part of each line; some 
lines that I am matching against will have a trailing slash, with 
additional path info that I'm not interested in; other lines will 
have a period and a number following, which I am also not interested 
in.


Perhaps the File::Basename module would do what I want, but I can't 
get my mind around its documentation.  I thought of using split on 
each line (splitting on the /, and then looking each element of the 
array returned), but that seems, well, stupid.  I'm sure that there 
is some really simple magic here; I just don't see it.  Can someone 
enlighten me please?

Thanks,
-s-
-- 
sandor w. sklar
unix systems administrator
stanford university itss-css