Re: 'which' functionality in Perl

2003-09-30 Thread Dirk Bremer \(NISC\)
- Original Message - From: "Arms, Mike" <[EMAIL PROTECTED]> To: "'Dax T. Games'" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Tuesday, September 30, 2003 13:03 Subject: RE: 'which' functionality in Perl > Dax T. Games

Re: 'which' functionality in Perl

2003-09-30 Thread Glenn Linderman
On approximately 9/30/2003 11:46 AM, came the following characters from the keyboard of Glenn Linderman: On approximately 9/30/2003 11:03 AM, came the following characters from the keyboard of Arms, Mike: Dax T. Games [EMAIL PROTECTED] wrote: How would I determine if a file existed in a directory

Re: 'which' functionality in Perl

2003-09-30 Thread Glenn Linderman
On approximately 9/30/2003 11:03 AM, came the following characters from the keyboard of Arms, Mike: Dax T. Games [EMAIL PROTECTED] wrote: How would I determine if a file existed in a directory in the PATH environment variable on a Windows box with Perl. If the file exists I want to return the f

RE: 'which' functionality in Perl

2003-09-30 Thread Arms, Mike
Dax T. Games [EMAIL PROTECTED] wrote: > How would I determine if a file existed in a directory in the > PATH environment variable on a Windows box with Perl. If the > file exists I want to return the full path to the file. > > The functionality I want is similar to 'which' on Unix/Linux. Dax,

RE: 'which' functionality in Perl

2003-09-29 Thread David 'Sniper' Rigaudiere
>> How would I determine if a file existed in a directory in the >> PATH environment variable on a Windows box with Perl. If the >> file exists I want to return the full path to the file. try this http://www.perl.com/language/ppt/src/which/index.html David "Sniper" Rigaudiere ___

RE: 'which' functionality in Perl

2003-09-29 Thread Tillman, James
You know, I found a funny way of emulating "which" using Perl a few years back. This doesn't solve your problem (it's already solved by the look of Helen Bennet's email), but is more along the lines of interesting related things. If you enter this at the command prompt: perl -S notepad.exe you

RE:'which' functionality in Perl

2003-09-28 Thread Alberto Adrian
You should try this: http://search.cpan.org/~sdague/ppt-0.12/  . It provides you all the *NIX utilities working in Perl and in DOS. There are lots of these *NIX tools, nowadays (Sourceforge). But what is interesting of this one is that you can get the code and learn a lot about how they are im

RE: 'which' functionality in Perl

2003-09-27 Thread Randy Kobes
On Sat, 27 Sep 2003, Helen Bennett wrote: > > -Original Message- > > From: [EMAIL PROTECTED] > > [mailto:[EMAIL PROTECTED] > > Behalf Of Dax T. Games > > Sent: 27 September 2003 22:10 > > To: [EMAIL PROTECTED] > > Subject: 'which' functionality in Perl > > > > How would I determine if a fi

RE: 'which' functionality in Perl

2003-09-27 Thread Helen Bennett
Hi There is probably a module somewhere that does it.. but the following function works as well .. may need to clean up the items returned from path as they may have "\" on the end, butt still works. Helen sub which ( $ ) { my ( $file ) = @_ ; $path = $ENV{"PATH"} ; foreach $dir (split

RE: 'which' functionality in Perl

2003-09-27 Thread Messenger, Mark
Title: RE: 'which' functionality in Perl Which, along with many other *nix commands, is included in the Unix95 set.  I can email this to you, or you can get it from http://whizzmo.com/unix95.zip (~1meg zip file). -Original Message- From: Dax T. Games [mailto:[EMAIL PROTEC