For Programmers: Free Programming Magazines  


Home > Archive > PERL Beginners > September 2007 > file search containing string









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author file search containing string
Nishi Bhonsle

2007-09-24, 10:03 pm

Hi:

How can I use perl to do the following -

--Look for a file on a filesystem containing a string such as
"Product Name 1.0.0.0.0"
--Then get the disk location path of the file and store the path in a variable.
--Pass the variable to an external java program.

Thanks a lot!
Paul Lalli

2007-09-25, 7:00 pm

On Sep 24, 4:46 pm, nishiandpraf...@gmail.com (Nishi Bhonsle) wrote:

> How can I use perl to do the following -
>
> --Look for a file on a filesystem containing a string such as
> "Product Name 1.0.0.0.0"


perldoc File::Find
perldoc perlretut

> --Then get the disk location path of the file and store the path in a variable.


perldoc File::Basename

> --Pass the variable to an external java program.


perldoc -f system


Once you've made an actual attempt, let us know if you encounter
difficulties, and we can probably help you fix it.

Paul Lalli

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com