Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?

Re: What can bring the excitement back to Perl?

by stvn (Monsignor)
on Mar 25, 2008 at 15:45 UTC ( #676144=note: print w/replies, xml ) Need Help??

in reply to What can bring the excitement back to Perl?

Well, I very much (respectfully) disagree with you, let me explain why.

Why is Perl not considered as awesome as PHP & Ruby? I have a couple theories on this actually ...

First PHP, it has a (very) low barrier of entry which makes it appealing to first time programmers. I am not sure anyone but those who have only ever programmed in PHP (maybe also in Javascript) think it is all that awesome. It does have a lot of nice "off the shelf" applications which are super easy to install (so sysadmins like them). The real killer app of PHP (IMO at least) is that you can write a fully functioning database driven web application, stuff it all in a single .php file, upload it to your $5 a month web host, and thats it, your done! No modules to install, no dependencies to track down, no servers to set up and configure, etc etc etc. It's so simple, it hurts. Perl simply does not have this "feature" 1, which is nice for those consultants which get paid by the hour and for those of us who care about long term maintainability and clean project organization. However this raises the barrier of entry and makes us cost more, two things which non-tech-savvy business folks (a.k.a - the guys writing the checks) care about very much.

Second is Ruby. Ruby, Ruby, Ruby, *sigh*. It's actually a very nice language, and Rails is a decent framework. The really funny thing is though, the killer app for Ruby is not (necessarily) a Ruby app at all, but just blogging software that is most often written in either Perl or PHP (oh the irony). Ruby has been made cool by countless bloggers (some good, a lot bad) who are spewing their love (infatuation) for the language all over the blogosphere. When you combine all this exposure with sites like Digg and Reddit and many thousands of bored and unhappy programmers you get a Hype Bubble that is impossible to burst 2.

But wait, this is not all Ruby has to offer, it's more than just hype. Imagine yourself stuck in a windowless cubicle, flourescent lights bathing everything in a cold, bland shade of blue, a cup of stale coffee next to your keyboard and nothing but Java as far as the IDE can see. Now imagine yourself sitting in a big comfy chair next to the window in your favorite coffee shop, sipping a triple-tall mocha-frapa-spresso with whipped cream 3 and joyfully writing 1 line of Ruby on Rails code for every 20-30 lines of Enterprise Java code. Which would you choose?

Ruby is object oriented all the way down, which appeals to the Java Junkie who has been told that this is the only acceptable way to be. Ruby's OO is clean too, not like that icky line-noisy Perl OO, or that awkward and kinda clunky Python, but clean,... like Java. Ruby also has lots of cool features like blocks, continuations, metaclasses, etc. which are fairly easy to play with and make you feel smart and clever when you use them. In short, Ruby is fun!

Of course the really funny thing about Ruby, outside of the recent wave of startups and larger cities, not really a lot of work is out there. It has not trickled down to the PHBs in Middle America who have small budgets and need to get things done. It's overall market penetration is fairly low compared to PHP, Java and even Perl. Sure it is growing, but the hype still far outstrips the reality on the ground.

So, to recap, we have PHP; low barrier of entry, easy to deploy. We have Ruby; super cool and sexy, easier to write then Java. How can Perl compete?

Perl 6, yeah maybe, when it comes out. Not to be pessimistic, but people will not be switching to Perl 6 on Xmas of 200x (we may need to start saying 20xx soon). I consider myself an early adopter and the earliest I would even consider using Perl 6 in production would be Xmas 200(x + 1). Why? Because it's a new untested language that is running on a new untested VM and $work is what pays the bills, so I will wait till I am convinced it is stable and ready for use (Of course being an early adopter means I will probably help out with that testing too, and I encourage everyone else to do so as well, it will only get us there quicker). And even still, Perl 6 will only give us the "super cool sexy" thing, it won't be any easier to deploy then Perl 5 (probably harder, at least initially), it won't be "easier to write then Java" since it won't have a "Perl 6 on Rails" (at least initially), and it's barrier for entry will be no lower (and maybe even a little higher) then Perl 5. So if we are really honest with ourselves, looking at Perl 6 as our savior is a long term strategy and doesn't really help things in the hear and now (in fact, it could be argued that all the FUD about Perl 6 actually hurts things).

CPAN, well, it is full of much more crap then it is good stuff, and this is hard to sift through for the uninitiated. The CPAN ecosystem is awesome and really has nothing that even comes close to competing with it. But if your not writing Perl code, then is useless to you. If the language itself cannot attract the people, then how will 16,000,000+ lines of code in that language make it any more appealing?

You say that Catalyst, DBIx::Class and Moose aren't exciting enough outside of the community to save us, but I disagree. Catalyst is (IMO at least) far superior to RoR in that it is very much not opinionated, it may be "just another MVC" but so what, it gets the job done. DBIx::Class actually is "something new", it beats every ORM I have looked at in terms of flexibility and robustness, and since it is built on top of DBI, it supports many more database vendors then most other ORMs out there in any language. Moose, well I am biased since I wrote it, but I know for a fact that the object model it provides is unlike anything else out there 4 and I have been told by several people that it is "fun" to program in (and one former Ruby programmer said it was as "fun" if not moreso then Ruby).

So to go back to our list:

  • Low Barrier for Entry (PHP)

    Perl has always been easy to learn, but hard to master. IMO at least, Catalyst, DBIx::Class and Moose help you start writing good code sooner. There is also things like Perl::Critic which can help to catch the bad things early on. We will never be as dumbed down as PHP is, but you know, I don't think that is a bad thing.

  • Ease of Deployment (PHP)

    Actually, I think we are getting closer on this one. Alias and others have been fixing this though their efforts with Strawberry Perl and the push to improve the CPAN toolchain. It seems that PAR has been improving some, making it a viable choice for easing your deployment pains. We still have a long way to go, but there is positive improvement here.

  • Super Cool & Sexy (Ruby)

    I am not sure if Perl will ever be sexy in the "tight-sweater, miniskirt and heels" way that Ruby is, but thats okay cause Perl is sexy in that "random-color dyed hair, black jeans and glasses" kinda way. (Sorry ladies, feel free to substitute the descriptions accordingly)

  • Easier then Java (Ruby)

    Well, we already have this through CPAN and more specifically, modules like Catalyst, DBIx::Class and Moose which promote cleaner code.

So why then is Perl not as popular as PHP and Ruby? Perhaps we just don't have enough people blogging about these new Perl technologies, generating the amount of hype needed to break out beyond this (giant) Perl echo chamber 5. A key feature of all of them is TIMTOWTDI, but with an emphasis on providing a more "correct" way to do things, rather then just creativity-run-wild. This kind of flexibility really can only be found in the Perl community, because it is so key to our culture. We need to get out there and promote this, show them it is a good thing and something they should use.

Okay, now I really need to get back to $work :)

  1. no Vanilla CGI does not count, besides you still have to chase modules and dependencies
  2. yes, Zed Shaw tried, but ultimately failed
  3. and a little cinnamon sprinkled on top, yummy
  4. It borrows from so many different sources (CLOS, Perl 6, Smalltalk, Ruby, Ocaml, BETA, Java, etc.) to produce a combination of features such that it only could be written in a language like Perl. Also, I keep tabs on new languages and technologies and I have yet to see something which is comparable.
  5. Perlmonks and use.perl don't count as "blogging" they are still inside the echo chamber.

  • Comment on Re: What can bring the excitement back to Perl?

Replies are listed 'Best First'.
Re^2: What can bring the excitement back to Perl?
by Errto (Vicar) on Mar 25, 2008 at 18:27 UTC

    Sort of OT, and I basically haven't used PHP or Ruby, but I want to reply to your comment about Javascript.

    In my experience, Javascript as a language has more to recommend it than a lot of people give it credit for. It has full support for dynamic typing, closures, resizeable arrays, associative arrays, a very flexible object system, and built-in regular expression support. Sort of like Perl, one might say. Now, Javascript also has some dark ugly corners, and it doesn't surprise me that it hasn't taken off in areas other than its one specialty of client-side web applications, but still.

      Javascript was my first language actually (I am not counting BASIC on the Apple ][e back in '85) so I completely agree with you.

      My comment about Javascript was not actually meant to be a slight against it. Only a clarification that most people who had only been exposed to PHP, were also likely to be exposed to Javascript too. But as you said, JS has some ugly dark corners to it which gives it an undeservedly bad rep.

Re^2: What can bring the excitement back to Perl?
by Casan (Novice) on Mar 26, 2008 at 01:16 UTC

    There are in particular two issues I have noticed that are not helping making perl more accessible.

    1. There is the old TIMTOWTDI/syntax issue which is also considered an asset of perl. Compared to java, perl has many more operators, symbols etc, which have different meanings in different context, and that is confusing and sometimes troublesome. Both newcomers and returners feel insecure. I think its hard to learn and to remember.
    2. Good guides, though I feel the community is very helpful, I also think that perl compared to ruby are lacking in relation to free open guides and examples. Ruby is blessed with its video and web tutorials, which are very user friendly compared to the perl offerings, maybe because Ruby have been 'hip' and have been embraced by the mac crowd that may be more experienced in communicating in a clear and visual fashion.

    Learning perl should be more fun and cool, not feeling like you have to read through a bunch of formulas in advanced math. Learners that benefit from faster yes experiences that are actually useful, will feel empowered and are more likely to show off and distribute in celebration which creates hype(if thats whats desired).

    One nice idea would be a website thats catering to users of different nature. That would be a website with individually targeted areas towards the following roles:

    • web application developers
    • system administration tool developers
    • desktop application developers
    Are there any other general typical roles using or who should be using perl?

    Such a website with a professional and user friendly presentation could feature application examples, video tutorials, slideshows (like those uploaded to slideshare, just more focused on actual problem examples), etc.

    I am well aware that those who could provide useful examples and tutoring through such a site rather like to do it through books and seminars from where they earn a living, but then if you don't want to build a crowd, don't expect there to be a crowd. Though some say we already are.

      I also think that perl compared to ruby are lacking in relation to free open guides and examples.

      Maybe I'm demonstrating the kind of old-school thinking that proves I'm out of step with kids these days, but have you tried to use Ruby's documentation? The only possible way it could compare with Perl's documentation is if an attractive member of the appropriate gender sat on your desk and read it out loud to you (and probably wrote your code for you, because Ruby's documentation is somewhat, well, slender).

        C I agree.

        Furthermore, many of the Ruby tutorials I have seen, have also been more for show than for actual use. They do something right, though not complete. I don't like to start a its either them or us thread, I will be perl biased too.

        I believe we can be more user friendly with our tutorials for learners, and Ruby documentation/tutorials can be more complete. is a nice approach, yet it can be more exciting and structured

        But as for the topic, when we are talking about what can bring the excitement back to Perl, then I think of both the newcomers, the returners and the old guard.

        Love perl6 btw, thanks.

Re^2: What can bring the excitement back to Perl?
by zby (Vicar) on Mar 25, 2008 at 16:26 UTC
    I would not say I disagree that much with you. That was a very systematic analysis about all the technical details. What I would like to add to this is a meditation on why people blog and talk so much about Rails. And my intuition is that this is because the integration of nice CSS and HTML templates with code libraries makes Rails a real breakthrough for individual programmers who can create nice looking sites without hiring web designers. This is not just number of lines of code or nice OO - it is something that without RoR is nearly not possible for a lonely programmer. And this is the kind of advantage that makes people blog about it.
      And my intuition is that this is because the integration of nice CSS and HTML templates with code libraries makes Rails a real breakthrough for individual programmers who can create nice looking sites without hiring web designers.

      I may very well be ignorant, but I didn't realize that Rails came with a web-design-in-a-box like that. Last I looked, the skeleton code is pretty decent, but far from "designed". In the end though, if you want to create a professional product, you will have to hire a web designer, and that is something that the Rubyists do seem to get more than any other language community.

      I think that while this is a good point, some of the new CSS "frameworks" like Blueprint, YUI Grid and more might make it a moot point. Also I have seen a trend in JS frameworks (in particular with JQuery which we use at work) to make it "look nice by default".


Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://676144]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (2)
As of 2022-05-18 22:31 GMT
Find Nodes?
    Voting Booth?
    Do you prefer to work remotely?

    Results (71 votes). Check out past polls.