Re: Regex on OS X
Re: Regex on OS X
- Subject: Re: Regex on OS X
- From: bill fancher <email@hidden>
- Date: Tue, 1 Oct 2002 16:23:17 -0700
On Tuesday, October 1, 2002, at 03:24 PM, John Delacour wrote:
At 2:38 pm -0700 1/10/02, bill fancher wrote:
Or you could avoid the bone-ugliness of perl (exacerbated by the need
to escape "\") and replace the last five lines with:
set JAN_HITS to do shell script "echo " & s & "|grep Jan"
Well apart from the fact that perl's beauty is without compare, you
obviously didn't bother to run my script to find out what it did and
I'm afraid you're going to have to disembellish and deminimize your
script somewhat in order to get it to do the same.
My script does what you *claimed* your script does: "print all lines
that contain 'Jan'". Is it my problem that your script isn't up to
spec? (I did run it, just didn't notice that it didn't do what it was
supposed to.)
I deliberately made the perl look ugly in order to tease out a
minimalist :-).
As if making perl ugly takes effort...
I've always considered perl a "minimalist" language. (Made for the
keyboard impaired. Can't get much more minimalist than "_".) So, in my
case, I consider my visceral dislike of perl a departure from my usual
attraction to the minimalist aesthetic.
(If grep doesn't do it for you, there's also sed, awk, egrep,...)
Not to speak of oux, fank, hhj, clak and fother.
I view discouraging the spread of perl as a civic duty. It's like kudzu.
--
bill
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.