Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Pulling Punches

by simonodell (Acolyte)
on Jul 12, 2011 at 00:54 UTC ( #913822=perlmeditation: print w/ replies, xml ) Need Help??

I've heard that around here people do not pull their punches, and indeed it appears that they also hand them out at the drop of a hat for whatever reason suits them. I've also heard this little rumour that humility is highly valued here, however according to experimental evidence, monks appear to speak highly of humility and yet show little evidence of knowing what the word actually means.

So I'm not going to pull any punches either, and believe it or not, merely pressing on with explaining my ideas here publically and for free, and requesting help with a problem I have found too difficult to solve single handed is a huge demonstration of humility.

Right now for the punches.

PHP IS KICKING PERL'S ASS.

Sorry! not sorry! If you, like me, live in the REAL world, you will be aware that it is getting harder to find perl jobs and that in job listings the number of PHP related jobs outnumbers perl jobs by maybe 5 to 1.

BUT PHP SUCKS.

We are into PERL, we all know why... no need to explain it, I'm sure we have all at some point been called to debug someones PHP based project, and seen a spaghetti mess reminiscent of something out of the film "brazil" come spewing out of our monitor screens. You know what I'm talking about, code and markup and even database calls all mashed into one big messy monolithic block of code with dozens of echo statements and the like. YUCK.

PERL NEEDS TO ADAPT AND EVOLVE OR ITS GOING TO DIE.

But despite it's many and numerous flaws, PHP is still taking over, and you have to ask yourself why that is. It's no good moaning about it and wishing the world would suddenly and magically discover what is so amazing about PERL, they won't, it is too complicated for most, requires too much discipline and effort to craft an elegant solution.

PERL IS FAST GOING THE WAY OF COBOL.

I did cobol at college, right after I had already got into and fallen in love with ANSI C (+asm for super whizzy fast turbo speed inner loops)... I'm sure you can imagine the horror I felt having to go BACKWARDS in terms of code abstraction level to a primitive, verbose, clunky and BORING old language. Infact COBOL was the root cause of me leaving college. I won't use primitive obsolete languages, period, won't do it.. no... fullstop. I'd rather be unemployed thank you goodbye.

I'M NOT HERE TO LEARN YOUR WAYS

I am not the sort of person who needs a teacher or a mentor, I am quite capable of solving any problem I come across or reverse engineering code in any language I choose. Ok well some problems are too difficult, however even those will be solved if I only had time to do it with. When I say too difficult I don't mean impossible, I mean it might take me to 2016 to solve, but I will solve it because I'm awesome and sexy.

MY PARADIGM IS BETTER THAN PHP

I chose PERL for the reasons you all choose PERL, because it rocks. But... and it is a big BUT, in the real world which many of you monks take great care to not interact with where possible, PHP is winning because it is so quick and easy to get results which please manager types who haven't got a clue about namespaces, $_, and all the other goodies which PHP completely lacks. But I'm a man with a plan, and you are the monks who are going to listen up, because I have solved the problem and my perl based paradigm is easier and quicker to get results with than PHP, and it comes with all the PERL yummyness you love so much.

F*** PHP

I refuse to work with the tonker toy language that is PHP, however I do see it's appeal to some, especially people who just want results fast. And fast is good, I hate wasting keystrokes, for a start I've got a pile of worn out keyboards and for seconds I would really rather avoid getting R.S.I. .. infact that is probably why I am not a java programmer. (don't get me started on that subject)

Ok so now I've given you a bit of an entertaining rant and established my awesome geek coder sexyness and utter lack of false humility, perhaps I should direct you to my other nodes wherein I have tried to explain things instead of just chatting away about things you all already know about.

ON THE OTHER HAND I CAN'T BE BOTHERED.

So I will leave you with this brief explanation and let you all get on with clicking the -- button or whatever it is you like to do with your spare monk time.

It's a bit like embperl only sexier.
It's a bit like HTML::Mason only less secretive and no funny handshakes.

Systems are built out of files which contain a mix of xmlesque tags and HTML.

Known tags are defined by plugins which are written in perl and have the full use of everything perl.

The $result of computing a child tag, becomes the $data of a parent tag.

The simple rules :

Rule 1 : Tags are computed from the innermost to the outermost, unless the tag delimiter type specifies otherwise.

Rule 2 : ( ) tags have the highest priority and compute prior to child tags of type < > and [ ].

Rule 3 : < > tags have the next highest priority and compute prior to tags of type [ ].

Rule 4 : [ ] tags have the lowest compute priority.

That's all!

Using this very simple set of rules, and by defining the meaning of tags using plugins, it is possible to provide a system which is easier and quicker to write apps in than PHP whilst still having all the power and stability of perl available and retaining compatibility with CPAN modules etc.

YOU CAN DO WHATEVER YOU WANT WITH IT

Unlike things like coldfusion etc, I am not trying to suggest that the names of the tags themselves are important, I don't want to limit things so that you have to type in <CFthis> <CFthat> etc, but instead allow you the freedom to decide what to call your own tags and what those tags should do.

for instance I have a tag called <loggedin> which only shows the data it contains if my framework agrees the current user is logged in. I could just as easily of called the plugin <anyonethere> or <wehaveuser> or anything really, it doesn't matter.. TIMTOWTDI

Well I'm going to stop ranting now and get on with being uber geeky sexy, because believe it or not, my time is actually valuable, and I believe that if you lot are half as good at programming as your collective attitude suggests, I have already just thrown a gauntlett down to you which you will not be able to resist picking up, and I have given you plenty of information that took me years of experiments to obtain and to refine the ruleset and test it's validity. (it always works)

IT WILL BE INTERESTING TO SEE IF ANY OF YOU ARE CODER ENOUGH TO WRITE AN IMPLEMENTATION OF THOSE RULES WHICH IS MORE EFFICIENT THAN MINE.

Comment on Pulling Punches
Select or Download Code
Re: Pulling Punches
by Anonymous Monk on Jul 12, 2011 at 02:14 UTC

    IT WILL BE INTERESTING TO SEE IF ANY OF YOU ARE CODER ENOUGH TO WRITE AN IMPLEMENTATION OF THOSE RULES WHICH IS MORE EFFICIENT THAN MINE.

    How could we know if its more efficient, you haven't shown yours?

Re: Pulling Punches
by Anonymous Monk on Jul 12, 2011 at 04:06 UTC
    My favorite punch is...
    1. Fruit
    2. Citrus
    3. Berry
    4. Tropical
    5. Hawaiian
    6. Red
    7. Spiked
    8. Sour
    9. Sucker
    10. Center
Re: Pulling Punches
by chromatic (Archbishop) on Jul 12, 2011 at 04:40 UTC

    The margin of this web site is too small to contain my implementation. Sorry.

      I'm sure that if it were efficient enough it would fit. :-P

      True laziness is hard work
Re: Pulling Fingers
by Your Mother (Canon) on Jul 12, 2011 at 05:56 UTC

    lc("PHP IS KICKING PERL'S ASS.")

    Some stats from indeed.com.

    php programmer: $37,000
    php developer: $56,000
    perl developer: $74,000

    Percentage of matching job postings–

    PHP: < 0.9% and rising
    Perl: > 1.1% and rising

    lc("BUT PHP SUCKS.")

    PHP is a perfectly reasonable language, is extremely facile with web work, and, like any other language, is as good as the hacker slinging it. You think wiki(pedia|media) just pulled itself out the great goatse?

    lc("PERL NEEDS TO ADAPT AND EVOLVE OR ITS GOING TO DIE.") =~ s/ITS/it’s/i

    Perl 5 releases are more frequent and more forward thinking than ever. Perl 6 is also on a steady release cycle. PHP won the low-rent web war, in part, admitting your only point, due to reticence in the Perl community to embrace the messy end of the WWW. Java, Ruby, Flash/Flex/AIR, and Python are more directly in competition with Perl for the mid–upper range web. Plack and Mojo and Dancer and others are opening the way back to the low-rent, one-off, quick-fix web again.

    lc("PERL IS FAST GOING THE WAY OF COBOL.")

    I'll enjoy the guaranteed annual salary increase then.

    lc("I'M NOT HERE TO LEARN YOUR WAYS")

    RLY!? UR DOIN IT RONG.

    lc("MY PARADIGM IS BETTER THAN PHP")

    And you’ll certainly make a million on it. Think of the embarrassment and humiliation we’ll all suffer watching you with envy in our bitter, cynical, unhelpful hearts.

    lc("F*** PHP")

    Study PHP. The community gets much right in many ways.

    lc("ON THE OTHER HAND I CAN'T BE BOTHERED.")

    In spite of the snark in my earlier reply I was giving a real answer meant to help even if the hand was a bit rough. You sound exactly like any dev reinventing templating for the first time. I’d wager 90% of the regular monks here have done a templating engine at least once and a lot of us have had to deal with some half-assed, quasi-XML, demi-perl, home-brew, file-based, legacy application code, or similar Java, and harbor the hurt to the day.

    You’ve described a system that can’t be stream parsed, can’t be readily consumed by available tools, has an inflexible file-only input system, will require running eval on raw Perl, seems to have arbitrary grammar coupled with a highly limited priority system which will always be expensive to parse, and brings nothing new to the game that couldn’t easily be done in TT or Mason or the Alloy family or… And they all have documents, community, examples, tests, profiling, and a really noticeable lack of ego about how effing Earth shattering their approach to solving this well-trod problem space is.

    If you would slow down and read some of the constructive, friendly replies you’ve got in the past on this topic instead of charging in here swinging a bag of insults on a stick, alternately swearing you’re done with us because we’re too dim to see your masterful insights that solve all web dev problems with perfect grace and asking for help with code you believe to be too awful to post.

    The simple rules–

    1. You do not talk about PerlMonks like it’s a code service.
    2. You do not talk about PerlMonks like it’s a code service that can be badgered, bullied, or emotionally extorted into building your spec.
    3. If someone says “troll,” invokes Godwin, or demands to have his account closed, the thread is over.
    4. Only two Monks to a fight.
    5. One thread at a time, fellas.
    6. Posts show your code. Show what your actually ran, the errors you got, and the output you expected.
    7. Threads will go on as long as long as two senior monks refuse to give in… …uh, how did that get in here?
    8. Final rule: if this is your first post at PerlMonks, someone has to explain to you that it’s Perl not PERL.

    lc("YOU CAN DO WHATEVER YOU WANT WITH IT")

    Round-filed!

    IT WILL BE INTERESTING TO SEE IF ANY OF YOU ARE CODER ENOUGH TO WRITE AN IMPLEMENTATION OF THOSE RULES WHICH IS MORE EFFICIENT THAN MINE.

    It will be uninteresting to see the follow-up post. But it might be fun to write another reply.

    Update: s/// bugfix from Tux++.

      >You’ve described a system that can’t be stream parsed,

      Yes it can, your just not smart enough to figure out how! having said that, stream parsing is a lame way of dealing with it.

      >can’t be readily consumed by available tools,

      Sure it can, but there is no need for that.

      >has an inflexible file-only input system,

      LOL.. you can store the data anyway you want, I was specifying a ruleset, not a framework!

      >will require running eval on raw Perl,

      You might think that, but you would be wrong... Again! I'm guessing you haven't read Higher Order Perl by Mark Jason Dominus then?

      >seems to have arbitrary grammar

      Oh so arbitary, horror of horrors it adds just 2 extra characters to the existing standard. PHP has <?, TT has [% how arbitary is that?

      >coupled with a highly limited priority system

      ROFL!!! Highly limited is a description of your imagination, not the system I proposed.

      >which will always be expensive to parse,

      Are you rabid about parsing or something? Parsing is always expensive no matter what, and besides its very old fashioned, insert COBOL joke here.

      >and brings nothing new to the game

      That's what you think, my dear little living the past perl monk.

      >that couldn’t easily be done in TT or Mason or the Alloy family or…

      It cannot be done in those or any other package I have found hence the reason I don't just use those packages... DUH!!!

      >And they all have documents, community, examples, tests, profiling,

      All of which takes time and effort I really can't be bothered to make. I have better things to do than to spoon feed you.

      >and a really noticeable lack of ego about how effing Earth >shattering their approach to solving this well-trod problem >space is.

      Cause and effect, showing humility here and lack of ego gets one response, going at it like a bull in a china shop gets an altogether more interesting (and useful) response.
        > And they all have documents, community, examples, tests, profiling,

        All of which takes time and effort I really can't be bothered to make. I have better things to do than to spoon feed you.

        This has nothing to do with spoonfeeding. Documentation (and exambles) offer a way to make the (end-)user understand what the module has to offer. If an example is clear and understandable, the possible (new) end-user can take a (quick) decision on the usefulness of the module and if it is going to help solving his/her problem.

        The better your examples are, the less errors the user will make, and the less bug reports you get.

        From your tone, also in other posts, I however think that you are not interested in bug reports, as your code - d'uh! of course - is without errors and self-explaining. So it doesn't need examples or documentation, as it will solve the problem on it's own. By pure magic. This is what the world was really waiting for.

        > and a really noticeable lack of ego about how effing Earth shattering their approach to solving this well-trod problem space is.

        Cause and effect, showing humility here and lack of ego gets one response, going at it like a bull in a china shop gets an altogether more interesting (and useful) response.

        That attitude might be what is causing your feelings here. The average monk here thinks that he/she can learn even from the most stupid post or question. By giving an explaining answer, it quite often happens that the poster gets a moment of WOW! which is most likely one of the reasons they post here.

        I came here years ago after taking ownership of an abandoned module, just to seek opinions of what other people thought that had to be improved or fixed. Meanwhile I learned that there is much more here that is worth learning about, even if I thought that I already knew all about that.

        Questions here make me sometimes re-read my own documentation to see where I was unclear. Sometimes that causes the docs to improve, sometimes I just have to tell the other person to re-read that part of the docs. Eventually examples and docs together make perfect sense.


        Enjoy, Have FUN! H.Merijn
Re: Pulling Punches
by JavaFan (Canon) on Jul 12, 2011 at 06:02 UTC
    Sorry! not sorry! If you, like me, live in the REAL world, you will be aware that it is getting harder to find perl jobs and that in job listings the number of PHP related jobs outnumbers perl jobs by maybe 5 to 1.
    So what? My bet is that the number of job listings for waiting tables outnumber the job listings for surgeons or pilots by much more than 5 to 1. That doesn't mean surgeons or pilots are going to COBOL way.

    And during the most recent YAPC, there were more companies announcing they were hiring than any other previous YAPC.

      HAHAHAHAHAHAHAHAHAHA!!!!!!!!!!

      That's all I got to say really!
Re: Pulling Punches
by Sandy (Deacon) on Jul 12, 2011 at 15:33 UTC
    Oh my!

    Never thought I would ever reply to a post like this, yet here I am.

    After much digging (I'm bored right now), I think that I might have figured out what you are going on about.

    If I figured it out correctly, you have defined a new paradigm in HTML templating, which you think is super cool, and wow, and why isn't everyone using it. But, your code that parses this new templating system is not as efficient as you would like.

    Here's the part that I think is rather interesting, from a human interaction point of view. You have thrown down a gauntlet. Your words:

    IT WILL BE INTERESTING TO SEE IF ANY OF YOU ARE CODER ENOUGH TO WRITE AN IMPLEMENTATION OF THOSE RULES WHICH IS MORE EFFICIENT THAN MINE.
    My interpretation: I am wonderful, I am smart, I bet you can't improve on what I have done. I dare you. I double dare you.

    Why? My guess... If someone gets angry enough, they just might come up with some code that deals with your pardigm, and then... YOU DON'T HAVE TO.

    Very sneaky. Almost smart.

      Yeah, this guy gets a pretty high score on the Crackpot Index (when adjusted for computer science rather than physics).

      I reckon we are the only monastery ever to have a dungeon stuffed with 16,000 zombies.

        Ah, it looks like I alluded to the Crackpot Index when we went around this whole thing four years ago. It seems that not much progress has been made. :-(

Re: Pulling Punches
by stonecolddevin (Vicar) on Jul 12, 2011 at 21:50 UTC

    People still talk about this shit?

    I could have understood if you had tried to say that Rails jobs outweigh perl jobs by that much, but PHP? Bad troll.

    Perl's got quite a few companies that use Perl in a HUGE way, mostly modern, and are hiring like there is no tomorrow (and paying quite well if I might add.

    Three thousand years of beautiful tradition, from Moses to Sandy Koufax, you're god damn right I'm living in the fucking past

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlmeditation [id://913822]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (8)
As of 2014-08-22 21:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (167 votes), past polls