Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!samsung!uunet!zephyr.ens.tek.com!tektronix!percy!littlei!nosun!omepd!merlyn From: merlyn@iwarp.intel.com (Randal Schwartz) Newsgroups: alt.sources.d Subject: Re: promoting Perl (was Re: uutraffic report (in perl)) Message-ID: <5294@omepd.UUCP> Date: 29 Nov 89 23:06:46 GMT References: <4025@mhres.mh.nl> <1194@radius.UUCP> <3273@convex.UUCP> <5261@omepd.UUCP> <1126@cirrusl.UUCP> <1989Nov28.064349.1421@eda.com> <14961@bfmny0.UU.NET> Sender: news@omepd.UUCP Reply-To: merlyn@iwarp.intel.com (Randal Schwartz) Organization: Stonehenge; netaccess via Intel, Hillsboro, Oregon, USA Lines: 44 In-reply-to: tneff@bfmny0.UU.NET (Tom Neff) In article <14961@bfmny0.UU.NET>, tneff@bfmny0 (Tom Neff) writes: | In article <1989Nov28.064349.1421@eda.com> jim@eda.com (Jim Budler) writes: | >I can't actually disagree with you, however, perl won me over with | >ONE simple example: | > | > % find -exec < most any command> \; | >versus | > % find -print | perl -ne 'equiv_command;' | > | >The performance improvement was HUGE! | | My goodness. | | It's a darn good thing the above quoted poster never read the man page | for xargs(1). | | He might have been won over by UNIX! :-) Come on. Suppose the operation was 'unlink;' or 'chmod 0644, $_;'. The perl commandline has two total processes, where even with xargs, you start *out* with three processes, and possibly more depending on the number of args. And of course, either of those are superior to the -exec solution, which is what the original poster had noticed. Of all people to speak, I should probably have it be known that I am *not* a "wild-eyed fanatic" for Perl! I have just noticed that it's a heckuva lot better to have an interpretive language designed for multiarchitecture system management than to resort to bizarre combinations of "standard" UNIX data-redux tools *if* you can get Perl up and running everywhere you need it, and can spend the time to learn to "think Perl", much like you learned to "think pipes and filters" when you started playing with UNIX. As others have noted, I still write 5-line awk scripts and shell scripts and C programs, but Perl does "fill a well-needed gap" :-) very nicely. (I don't subscribe to alt.religion.computers -- maybe this belongs there? :-) Just another Perl hacker, -- /== Randal L. Schwartz, Stonehenge Consulting Services (503)777-0095 ====\ | on contract to Intel's iWarp project, Hillsboro, Oregon, USA, Sol III | | merlyn@iwarp.intel.com ...!uunet!iwarp.intel.com!merlyn | \== Cute Quote: "Welcome to Oregon... Home of the California Raisins!" ==/ Brought to you by Super Global Mega Corp .com