Re: kills Padre 0.84 on execution

2011-06-12 Thread Sayth Renshaw
> If you go to Tools / Preferences / Run Parameters and check 'Use > external window for execution' then Padre will start up a new cmd window > for execution which will respond as you expect. > > Rob > Thanks. -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-m

Re: using Perl, How to search for files in my computer

2011-06-12 Thread Brian F. Yulga
shawn wilson wrote: On Sun, Jun 12, 2011 at 14:38, Brian F. Yulga wrote: perl -MFile::Find -wle "find( sub{ /\.mp3$/i and print;}, q(.));" just curious, what's the difference (in speed or results) between this and 'dis/a/s/b *.mp3'? obviously File::Find and perl are more powerful,

Re: using Perl, How to search for files in my computer

2011-06-12 Thread Brian Fraser
use File::Find::Rule; my @mp3_files = File::Find::Rule->file->name(qr/ \. mp3$ /x)->in("C:/"); Tada. The problem with this (and all previous) solutions is that, if you have filenames with non-English (bah, ascii/latin-1) characters, you'll get a bunch of garbage instead. I'm not aware if there's

Re: using Perl, How to search for files in my computer

2011-06-12 Thread shawn wilson
On Sun, Jun 12, 2011 at 14:38, Brian F. Yulga wrote: > > Hi Sayth, et. al., > > At work I'm stuck on Winblows, and this is one of the ways Strawberry Perl > (portable install) saves me lots of time.  There's nothing wrong with the > other solutions presented; I'm just adding to the variety...  I u

Re: using Perl, How to search for files in my computer

2011-06-12 Thread Brian F. Yulga
Sayth Renshaw wrote: Try: my @Music_files = (); use File::Find; find( \&want_mp3, 'd:\\' ); print "$_\n" for sort @Music_files; sub want_mp3 { push @Music_files, $File::Find::name if $_ =~ /\.mp3$/; } -- Just my 0.0002 million dollars worth, Shawn Confusion is the first step of unde

Re: kills Padre 0.84 on execution

2011-06-12 Thread Rob Dixon
On 12/06/2011 14:08, Sayth Renshaw wrote: I created a simple script to test whether the Padre output console would except input via. After creating the script I pressed F5; no output is put to the console. I waited about 30 seconds - 1 min still nothing I stopped the process executing. This was

kills Padre 0.84 on execution

2011-06-12 Thread Sayth Renshaw
I created a simple script to test whether the Padre output console would except input via . After creating the script I pressed F5; no output is put to the console. I waited about 30 seconds - 1 min still nothing I stopped the process executing. This was the script. #!/usr/bin/perl print " Give

Re: using Perl, How to search for files in my computer

2011-06-12 Thread John Delacour
At 03:40 -0700 12/06/2011, eventual wrote: I've read perldoc File::Find but I dont understand. So If I wish to search for "mp3" in d:\ and all its sub-directories, and to print it out if found, How should I write? Just put the directory in $dir: #!/usr/local/bin/perl use strict; use File::

Re: using Perl, How to search for files in my computer

2011-06-12 Thread Sayth Renshaw
> Try: > > my @Music_files = (); > > use File::Find; > find( \&want_mp3, 'd:\\' ); > print "$_\n" for sort @Music_files; > > sub want_mp3 { >  push @Music_files, $File::Find::name if $_ =~ /\.mp3$/; > } > > > -- > Just my 0.0002 million dollars worth, >  Shawn > > Confusion is the first step of

Re: using Perl, How to search for files in my computer

2011-06-12 Thread shawn wilson
On Jun 11, 2011 11:15 AM, "eventual" wrote: > > Hi, > I am using windows7. > Using Perl, how do I search for files in my computer, eg to search in c:\ and all its sub-directories. > I only know how to use glob to search from a particular location. > Thanks I haven't seen any mention of find2perl

Re: using Perl, How to search for files in my computer

2011-06-12 Thread Shawn H Corey
On 11-06-12 06:40 AM, eventual wrote: I've read perldoc File::Find but I dont understand. So If I wish to search for "mp3" in d:\ and all its sub-directories, and to print it out if found, How should I write? Try: my @Music_files = (); use File::Find; find( \&want_mp3, 'd:\\' ); print "$_\n"

Re: using Perl, How to search for files in my computer

2011-06-12 Thread Sayth Renshaw
Actually got it working. You would need to use File::Find to search sub directories however. #!\usr\bin\perl use warnings; use strict; use diagnostics; use File::List; my $mp3; my @musiFiles; $mp3 = new File::List("C:/Users/RenshawFamily/maven/Music/Foo Fighters"); my @musicFiles = @{ $mp3->find(

Re: using Perl, How to search for files in my computer

2011-06-12 Thread Sayth Renshaw
On Sun, Jun 12, 2011 at 8:40 PM, eventual wrote: > Thanks, > I've read perldoc File::Find but I dont understand. > So If I wish to search for "mp3" in d:\ and all its sub-directories, and to > print it out if found, > How should I write? > Thanks > > > From: Shawn H Corey > To: beginners@perl.or

Re: using Perl, How to search for files in my computer

2011-06-12 Thread eventual
Thanks, I've read perldoc File::Find but I dont understand. So If I wish to search for "mp3" in d:\ and all its sub-directories, and to print it out if found, How should I write?  Thanks From: Shawn H Corey To: beginners@perl.org Sent: Saturday, June 11, 2011 11:31 PM Subject: Re: using Perl, H

Re: Loading library different per Operating System

2011-06-12 Thread JPH
Here is how I solved it: use if $^O eq "linux" , "Device::SerialPort" => qw( :PARAM :STAT 0.07 ); use if $^O eq "MSWin32" , "Win32::SerialPort" => qw( :PARAM :STAT 0.19 ); Thanks! On 06/12/2011 03:13 AM, Dr.Ruud wrote: On 2011-06-11 17:20, JP wrote: How can I load a library depending on