From faber at linuxnj.com Fri Mar 4 18:50:23 2005 From: faber at linuxnj.com (Faber Fedor) Date: Fri Mar 4 18:50:35 2005 Subject: [ABE.pm] returning an array from a subroutine Message-ID: <20050305025023.GB12501@uranus.faber.nom> How to do it? I've got a sub routine that creates an array (it could be sizeable but I'll worry about that later). I've tried every permutation I can think of to return the array to the calling function: @my_array = foobar() and in the func do a "return @another_array" foobar(@myarray) and populating it inside the func foobar(\@myArray) and populating it inside the func The only thing I can think of doing now is to flatten the array into a string. I can't believe that's how it's suppposed to be done. -- Regards, Faber Linux New Jersey: Open Source Solutions for New Jersey http://www.linuxnj.com From jce0 at Lehigh.EDU Fri Mar 4 19:56:27 2005 From: jce0 at Lehigh.EDU (Jim Eshleman) Date: Fri Mar 4 19:56:44 2005 Subject: [ABE.pm] returning an array from a subroutine In-Reply-To: <20050305025023.GB12501@uranus.faber.nom> References: <20050305025023.GB12501@uranus.faber.nom> Message-ID: <42292DEB.8070208@Lehigh.EDU> > How to do it? > > > I've got a sub routine that creates an array (it could be sizeable but > I'll worry about that later). I've tried every permutation I can think > of to return the array to the calling function: > > @my_array = foobar() and in the func do a "return @another_array" > foobar(@myarray) and populating it inside the func > foobar(\@myArray) and populating it inside the func > > The only thing I can think of doing now is to flatten the array into a > string. I can't believe that's how it's suppposed to be done. > AFAIK you just do what seems natural: $ cat test.pl #!/usr/bin/perl -w use strict; my @my_array = foobar(); print "@my_array\n"; exit; sub foobar { my @another_array = (0,1,2,3); return @another_array; } $ ./test.pl 0 1 2 3 $ -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 252 bytes Desc: OpenPGP digital signature Url : http://mail.pm.org/pipermail/abe-pm/attachments/20050304/d958ef52/signature.bin From faber at linuxnj.com Sat Mar 5 09:22:36 2005 From: faber at linuxnj.com (Faber Fedor) Date: Sat Mar 5 09:22:46 2005 Subject: [ABE.pm] Config files Message-ID: <20050305172236.GA15632@uranus.faber.nom> I want to include a config file in my application. IT just consists (so far) of a bunch of $foo=bar; $bar=foo; and the like. What's the canonical way to include that file in my program? I tried include './myconfig.pl' but that's look in @INC. "do './myconfig.pl'" didn't work either. -- Regards, Faber Linux New Jersey: Open Source Solutions for New Jersey http://www.linuxnj.com From faber at linuxnj.com Sat Mar 5 09:24:13 2005 From: faber at linuxnj.com (Faber Fedor) Date: Sat Mar 5 09:24:22 2005 Subject: [ABE.pm] Re: returning an array from a subroutine In-Reply-To: <42292DEB.8070208@Lehigh.EDU> References: <20050305025023.GB12501@uranus.faber.nom> <42292DEB.8070208@Lehigh.EDU> Message-ID: <20050305172413.GB15632@uranus.faber.nom> On 04/03/05 22:56 -0500, Jim Eshleman wrote: > > AFAIK you just do what seems natural: You do. My problem was spending too much time in front of the computer yesterday. I got back to it this morning and within a half hour had things working the way I want. :-) -- Regards, Faber Linux New Jersey: Open Source Solutions for New Jersey http://www.linuxnj.com From rjbs-perl-abe at lists.manxome.org Sat Mar 5 09:50:18 2005 From: rjbs-perl-abe at lists.manxome.org (Ricardo SIGNES) Date: Sat Mar 5 09:50:28 2005 Subject: [ABE.pm] Config files In-Reply-To: <20050305172236.GA15632@uranus.faber.nom> References: <20050305172236.GA15632@uranus.faber.nom> Message-ID: <20050305175018.GL29308@manxome.org> * Faber Fedor [2005-03-05T12:22:36] > I want to include a config file in my application. IT just consists (so > far) of a bunch of > > $foo=bar; > $bar=foo; > > and the like. > > What's the canonical way to include that file in my program? I tried It is not something that is generally done. One doesn't usually evaluate some external Perl and have its scope merged with the current one. Have you looked at any of the Config:: modules? Personally, I tend to use YAML for this sort of thing. Check out the YAML module. typical yaml file (indented by one tab): foo: bar bar: foo people: bob: banker ted: lawyer joe: pizza guy hosts: - host1 - host2 - host3 Config::Auto is good, too. -- rjbs -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: not available Url : http://mail.pm.org/pipermail/abe-pm/attachments/20050305/b3eba6f9/attachment.bin From glim at mycybernet.net Sat Mar 19 12:24:00 2005 From: glim at mycybernet.net (glim@mycybernet.net) Date: Sat Mar 19 12:51:28 2005 Subject: [ABE.pm] Yet Another Perl Conference, North America, 2005 Registration now open Message-ID: ----------> Yet Another Perl Conference, North America, 2005 Registration now open. Conference dates: Monday - Wednesday 27 - 29 June 2005 Location: 89 Chestnut Street http://89chestnut.com/ University of Toronto Toronto, Ontario, Canada Info at: http://yapc.org/America Direct registration: http://donate.perlfoundation.org/index.pl?node=registrant%20info&conference_id=423 Full registration fee $85 (USD) Book now for great deals on accommodations and ensure a space for yourself. Speaking slots are still open. If you would like to present at YAPC::NA 2005, see: http://yapc.org/America/cfp-2005.shtml Details of this announcement: http://yapc.org/America/registration-announcement-2005.txt <---------- More Details ============ Registration for YAPC::NA (Yet Another Perl Conference, North America) 2005 in Toronto, Ontario, Canada is now open. The conference registration price is USD$85. This price includes admission to all aspects of the conference, respectable amounts of catering, several activities and a few conference goodies. The YAPC North America 2005 conference features... * Fantastic speakers + most are the core creators of the technology on which they present + many are professional IT authors, trainers and conference speakers * An excellent learning opportunity * A chance to meet Perl professionals from all over North America and the world + YAPC attendees tend to be very involved in Perl and so are another great way to learn more about what the language has to offer beyond just what the speakers have to say * Extra-curricular / after hours activities * A great location in downtown Toronto All this, and the price is more than an order of magnitude cheaper than what commercial conferences can offer. This is because YAPC is a 100% volunteer effort, both from its organizers and its speakers. Quality is *not* sacrificed to achieve this stunning level of affordability. YAPC provides the best value-for-dollar in IT conferences. And it's a ton of fun, too. The dates of the conference are Monday - Wednesday 27-29 June 2005. The location is 89 Chestnut Street in downtown Toronto, Ontario, Canada. (Note that a different date block was previously announced; we moved the conference date to accommodate venue availability.) http://89chestnut.com/ -- a facility within the University of Toronto If you are at all interested in attending the conference... Book now! Book now! Book now! We have room for about 400 attendees and we hope to sell out well in advance of the late June conference date. However, the critical matter is that of hotels. The YAPC::NA 2005 organizers have made group arrangements with several facilities around the city to provide _excellent_ quality accommodations in _very_ convenient locations at _terrific_ prices for the _full_ capacity of conference attendees (around 400 people). (Finding, booking and paying accommodations is the responsibility of the attendees, but we will provide you with a list of the hotels and university dorms to try first based on our group arrangement with them when you register for the conference. Also, see the web site at http://yapc.org/America/accommodations-2005.shtml. More details will be up shortly. The dorm option will be approx. C$55/night, the hotel options will be more like C$90/night, and for slightly different prices there will be options for putting more than 1 person in a room. Exact details and how to book will be emailed directly to people who have registered for the conference as soon as they become available.) *The catch is -- book now!!* The group reservations will expire in early May, at which point in time the group rates will mostly still apply, but the rooms will be given out on an "availability basis". Which means that someone else outside of the YAPC group can book the rooms as well. Make no mistake -- the rooms *will* be sold. Toronto is a very active conference city in the summer and there will be _no_ guarantee of vacancies either at the facilities we made arrangements with or anywhere else in the city if you leave it to within 6 weeks of the conference date. So, if you want to save yourself the likely-fruitless headache of scrambling around looking for accommodations at the last minute, Book now! Book now! Book now! Have any questions? Email na-help@yapc.org for more details. Additionally, we are still welcoming submissions for proposals via: http://yapc.org/America/cfp-2005.shtml The close of the call-for-papers is April 18, 2005 at 11:59 pm (Toronto time). If you have any questions regarding the call-for-papers or speaking at YAPC::NA 2005 please email na-author@yapc.org We would love to hear from potential sponsors. Please contact the organizers at na-sponsor@yapc.org to learn about the benefits of sponsorship. From rjbs-perl-abe at lists.manxome.org Tue Mar 22 06:35:30 2005 From: rjbs-perl-abe at lists.manxome.org (Ricardo SIGNES) Date: Tue Mar 22 06:35:38 2005 Subject: [ABE.pm] higher order perl - review copies? Message-ID: <20050322143530.GR22562@manxome.org> Mark-Jason Dominus's "Higher Order Perl" will be out on shelves, soon. http://perl.plover.com/hop/ It's about writing code to write code, and from everything I've heard it is totally awesome. I already have a copy on order, and hope to have it in my hands soon. If anyone is interested in writing a review, though, I can ask Mark to ask his publisher to send us a review copy that we can pass around. (I'd rather not ask for it if we don't provide reviews, though.) Is anyone interested? -- rjbs -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: not available Url : http://mail.pm.org/pipermail/abe-pm/attachments/20050322/727099dc/attachment-0001.bin From rjbs-perl-abe at lists.manxome.org Tue Mar 22 06:37:25 2005 From: rjbs-perl-abe at lists.manxome.org (Ricardo SIGNES) Date: Tue Mar 22 06:37:33 2005 Subject: [ABE.pm] YAPC? Message-ID: <20050322143725.GS22562@manxome.org> Summer approaches, and with it YAPC. I am definitely going to head up there again. Richard Dice, of the Toronto Perl Mongers, says they're hoping to nearly double the attendance since Buffalo. It looks to be a cheap conference, maybe even cheaper than last year. I think the lodging rates are much lower, anyway. Anyone else planning on going, yet? -- rjbs -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: not available Url : http://mail.pm.org/pipermail/abe-pm/attachments/20050322/14a143a5/attachment.bin From faber at linuxnj.com Wed Mar 23 18:02:55 2005 From: faber at linuxnj.com (Faber Fedor) Date: Wed Mar 23 18:03:05 2005 Subject: [ABE.pm] regex problem? Message-ID: <20050324020255.GB3217@uranus.faber.nom> I have a file (test.php) that contains lines like this: I want to change those line to look like this: So I do this (and several variations): perl -i.bak -e 's/\<\? /\<\?php /g' test.php But nothing changes and no test.php.bak file is created. Why? -- Regards, Faber Linux New Jersey: Open Source Solutions for New Jersey http://www.linuxnj.com From rjbs-perl-abe at lists.manxome.org Wed Mar 23 18:17:53 2005 From: rjbs-perl-abe at lists.manxome.org (Ricardo SIGNES) Date: Wed Mar 23 18:18:06 2005 Subject: [ABE.pm] regex problem? In-Reply-To: <20050324020255.GB3217@uranus.faber.nom> References: <20050324020255.GB3217@uranus.faber.nom> Message-ID: <20050324021753.GB348@manxome.org> * Faber Fedor [2005-03-23T21:02:55] > perl -i.bak -e 's/\<\? /\<\?php /g' test.php You forgot -p -- rjbs -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: not available Url : http://mail.pm.org/pipermail/abe-pm/attachments/20050323/36685149/attachment.bin From faber at linuxnj.com Wed Mar 23 18:20:31 2005 From: faber at linuxnj.com (Faber Fedor) Date: Wed Mar 23 18:20:39 2005 Subject: [ABE.pm] Re: regex problem? In-Reply-To: <20050324020255.GB3217@uranus.faber.nom> References: <20050324020255.GB3217@uranus.faber.nom> Message-ID: <20050324022031.GA3349@uranus.faber.nom> Because I forgot the '-p', that's why. On 23/03/05 21:02 -0500, Faber Fedor wrote: > I have a file (test.php) that contains lines like this: > > > > I want to change those line to look like this: > > > > So I do this (and several variations): > > perl -i.bak -e 's/\<\? /\<\?php /g' test.php > > But nothing changes and no test.php.bak file is created. Why? > > -- > > Regards, > > Faber > > Linux New Jersey: Open Source Solutions for New Jersey > http://www.linuxnj.com > > > > _______________________________________________ > ABE-pm mailing list > ABE-pm@pm.org > http://mail.pm.org/mailman/listinfo/abe-pm -- Regards, Faber Linux New Jersey: Open Source Solutions for New Jersey http://www.linuxnj.com From stigliz at gmail.com Thu Mar 24 14:26:44 2005 From: stigliz at gmail.com (Amedeo Guffanti) Date: Thu Mar 24 14:26:51 2005 Subject: [ABE.pm] Reseach on Open Source Developers Message-ID: Hi, I'm Amedeo Guffanti, a 22 years old Italian student at Bocconi university in Milan, I' m doing a research to write a work about Open Source Movement, in particular, about the developers. I try to collect the opinions of developers like you. My little poll is at this page : http://www.alberocavo.com/OSSprojects.asp It takes less then 4 minutes. I hope the Open Source Communities will give me a help for my research. I apologize for taking your time and for my English that I hope it's understandable ^^ Sincerly, Amedeo Guffanti