Using / of unix and \ of windows for copying files

2009-01-18 Thread Sarsamkar, Paryushan
Hi All, I want to write a single Perl script to copy some files from one machine to another. Those can be windows or unix. Is that possible to have one script to do it? The script that I have written is as follows which do the job for windows to windows. The problem here is if user says tar

Perl-R bridge

2009-01-18 Thread ANJAN PURKAYASTHA
Hi, I'm planning to access R from my perl scripts. The only noteworthy bridge seems to be Statistics-R-0.03. Would anyone like to share their experience with this Perl-R bridge? I'd like to install it in a Mac OS X. Suggestions on

Re: Updating Perl 5.8.8 to 5.10 under MacOSX and Eclipse EPIC

2009-01-18 Thread Steven Sankaran
Hm. I have spent the last hour or so attempting to get this to work, but I cannot seem to get Perl to update. I have located the 5.10 directory under /usr/local/ActiveState-5.10 but I cannot get Eclipse to recognize it. I even tried Eclipse and EasyEclipse. Does anyone have any other IDE suggestion

Re: What does MakeFile do?

2009-01-18 Thread Owen
> Which is obviously a real beginner question. I have googled around, > but all the info I have found assumes you have access to the server. > > My sites are shared hosting accounts located at Earthlink, Verio, > GoDaddy, etc. I have used a number of scripts which I can use just by > ftp uploading

What does MakeFile do?

2009-01-18 Thread Lewis Kirk
Which is obviously a real beginner question. I have googled around, but all the info I have found assumes you have access to the server. My sites are shared hosting accounts located at Earthlink, Verio, GoDaddy, etc. I have used a number of scripts which I can use just by ftp uploading text fil

Re: Newbie question about variables, arrays and where they all go

2009-01-18 Thread Telemachus
From: Telemachus Date: Sun, 18 Jan 2009 20:17:27 -0500 To: beginners@perl.org Subject: Re: Newbie question about variables, arrays and where they all go On Sun Jan 18 2009 @ 7:54, Telemachus wrote: > The arguments to a subroutine go into the @_ array. The @numbers array is > empty until you load

Re: Updating Perl 5.8.8 to 5.10 under MacOSX and Eclipse EPIC

2009-01-18 Thread Telemachus
On Sun Jan 18 2009 @ 4:35, Steven Sankaran wrote: > Hello, > So, I was going through a tutorial and I realized that my Eclipse > install is using an older version of Perl that does not recognize the > "say" command. I have attempted updating Perl to 5.10 using the > ActivePerl-5.10.pkg ,however, a

Re: Newbie question about variables, arrays and where they all go

2009-01-18 Thread Telemachus
On Sun Jan 18 2009 @ 10:59, dolphin_sonar wrote: >1 # When calling 'running_sum(5, 6);' the variable 'state @numbers' > receives those two >2 # parameters, (5 and 6), right? Then, the @numbers array also > copies/stores (5 and 6) >3 # into the special '( @_ )' variable as well, right? A

Updating Perl 5.8.8 to 5.10 under MacOSX and Eclipse EPIC

2009-01-18 Thread Steven Sankaran
Hello, So, I was going through a tutorial and I realized that my Eclipse install is using an older version of Perl that does not recognize the "say" command. I have attempted updating Perl to 5.10 using the ActivePerl-5.10.pkg ,however, as far as I can tell, that doesn't seem to be working. I am cu

Re: Using hashes in a format

2009-01-18 Thread John W. Krahn
Adam Jimerson wrote: Yea I read that dbmopen was superseded by the "tie" function but I couldn't figure out the permissions for it: tie(%HIST, 'NDBM_File', '/usr/lib/news/history', 1, 0); perldoc DB_File [ snip ] Default Parameters It is possible to omit some or all of the final

Newbie question about variables, arrays and where they all go

2009-01-18 Thread dolphin_sonar
1 # When calling 'running_sum(5, 6);' the variable 'state @numbers' receives those two 2 # parameters, (5 and 6), right? Then, the @numbers array also copies/stores (5 and 6) 3 # into the special '( @_ )' variable as well, right? Also, line 13 pushes '$number' into 4 # the '@numbers' ar

Re: Using hashes in a format

2009-01-18 Thread Adam Jimerson
"John W. Krahn" wrote: > Adam Jimerson wrote: >> I am working on a program that will act as a contact manager of sorts, >> it uses two hashes to store everything (although the second one is >> commented >> out because I am not ready to work with it). I am using the format >> function to display

Re: Using hashes in a format

2009-01-18 Thread Adam Jimerson
(Randal L. Schwartz) wrote: >> "Adam" == Adam Jimerson writes: > > Adam> my %phone_numbers = (); > ... > Adam> $phone_numbers{$_} #needs to print the keys of the hash for the > name, and Adam> values for the phone number so it will be like this "Some > Name 555-555-" Adam> . > > Back in

Re: Using hashes in a format

2009-01-18 Thread Randal L. Schwartz
> "Adam" == Adam Jimerson writes: Adam> my %phone_numbers = (); ... Adam> $phone_numbers{$_} #needs to print the keys of the hash for the name, and Adam> values for the phone number so it will be like this "Some Name 555-555-" Adam> . Back in the day, formats couldn't access lexical (m

Re: Using hashes in a format

2009-01-18 Thread John W. Krahn
Adam Jimerson wrote: I am working on a program that will act as a contact manager of sorts, it uses two hashes to store everything (although the second one is commented out because I am not ready to work with it). I am using the format function to display everything but I don't know how to ge

Make substitution output depend on buffer state

2009-01-18 Thread Markus
Hi, I have a list of different text patterns and I'm only interested in a certain part of their content, which is different for each pattern. The main constraint is doing this within a substitution statement. $split_regex has 4 different expressions with one buffer each. Each input string conta

Re: Perl UNIX shell PATH problem

2009-01-18 Thread Mr. Shawn H. Corey
On Sun, 2009-01-18 at 15:36 +, Andy Smith wrote: > Odd one, must be missing something basic! :P > The problem is that your servers were set up at different times. Or rather, your company does not have rigorous policies for setting up servers. Your development and test environments must be a

Re: Perl UNIX shell PATH problem

2009-01-18 Thread Andy Smith
Hi, yep, /etc/profile the same on both systems: ls -ld /etc/profile* -rw-r--r-- 1 root wheel 2032 Jan 16 15:40 /etc/profile -rw-r--r-- 1 root wheel 645 Jan 16 15:40 /etc/profile.old ls -ld /etc/profile* -rw-r--r-- 1 root wheel 2032 Jul 13 2006 /etc/profile (I copied the profile f

Re: String replacement involving special characters.

2009-01-18 Thread Gunnar Hjalmarsson
Blue wrote: $string = "aaa ' ccc "; $string =~ s/'/bbb/eg; The above replaces the single-quotation mark with bbb. The result will be: aaa bbb ccc How do I modify it so that the single-quotation mark is replaced with \' (a backslash and a single-quotation mark) resulting in: aaa \' ccc Is ther

RE: Query : Exectuting flow in parllel dirs

2009-01-18 Thread vivekananda.mohana
Hi, Pls help with the correct syntax. Appreciate the help. Thanks Regards, Vivek From: Vivekananda Mohana (WT01 - PES-Semi-Technology) Sent: Friday, January 16, 2009 3:23 PM To: 'beginners@perl.org' Subject: Query : Exectuting flow in parllel dirs Hi, I ha

Using hashes in a format

2009-01-18 Thread Adam Jimerson
I am working on a program that will act as a contact manager of sorts, it uses two hashes to store everything (although the second one is commented out because I am not ready to work with it). I am using the format function to display everything but I don't know how to get it to show the keys

Re: String replacement involving special characters.

2009-01-18 Thread Mr. Shawn H. Corey
On Fri, 2009-01-16 at 10:56 -0800, Blue wrote: > $string = "aaa ' ccc "; > $string =~ s/'/bbb/eg; > > The above replaces the single-quotation mark with bbb. The result will > be: > aaa bbb ccc > > How do I modify it so that the single-quotation mark is replaced with > \' (a backslash and a single

String replacement involving special characters.

2009-01-18 Thread Blue
$string = "aaa ' ccc "; $string =~ s/'/bbb/eg; The above replaces the single-quotation mark with bbb. The result will be: aaa bbb ccc How do I modify it so that the single-quotation mark is replaced with \' (a backslash and a single-quotation mark) resulting in: aaa \' ccc -- To unsubscribe, e

Maximizing IE using Win32::IEAutomation

2009-01-18 Thread Collaborate
I use the following to open a webpage with the intent to have the IE window maximized. However, the window opens in a small size. my $ie = Win32::IEAutomation->new(visible=>1, maximize=>1); $ie->gotoURL('http://www.google.com', 0); Is there anything that needs to be done differently? Are there o