Re: Finding Filenames that contain a certain string
Re: Finding Filenames that contain a certain string
- Subject: Re: Finding Filenames that contain a certain string
- From: has <email@hidden>
- Date: Sat, 21 Jul 2007 19:49:19 +0100
Michelle Steiner wrote:
Thing is that the "pure applescript" solution is understandable
even by beginners,
This is only half-true. It's true that AS's English-like appearance
makes it easy for non-programmers to guess what a script does, but
its ambiguous syntax and obfuscated semantics make it hard to
understand how it actually does it - which also makes it hard to
learn how to write your own.
whereas the regex solution is pure gibberish to anyone who doesn't
already know regex.
Correct. However, once you learn how to interpret the regex syntax
it's straightforward to understand what any given regex does. That's
because the regex syntax is precisely defined and totally predictable
and clearly describes the underlying semantics.
The thing about AppleScript is that it's a fundamentally dishonest
language: it pretends to be much easier than it actually is in order
to entice new users through the door, only to subsequently pull a
bait-n-switch on them as soon as they're in.
And here's the thing: a newcomer with no previous experience of
programming won't even realise that they've just been had: they'll
simply assume that this is how things must be, and breathe a sigh of
relief that if this is what's considered an "easy" language, it's
just as well they didn't try a "hard" language like Python or Ruby
because those must be a hundred times worse. OTOH, when folk who
started out on other more traditional languages start to learn
AppleScript it's not surprising they should grumble, because they
already have gained the experience that tells them that it shouldn't
be nearly as hard going as it is.
So while it is true that it's harder to get onto that first rung in
Python or Ruby, if you're willing to put in that extra initial
effort, the subsequent climb turns out to be much less difficult than
in AppleScript. That's because the Python and Ruby ladders have nice,
solid rungs spaced evenly at regular one-foot intervals. Whereas the
AppleScript ladder may put the first rung three inches from the
ground but subsequent rungs vary from 12 inches to three or four feet
apart and some have hidden woodworm too just to add to the fun.
File under "You get what you pay for" and "If it sounds to good to be
true, it usually is".
Cheers,
has
--
http://appscript.sourceforge.net
http://rb-appscript.rubyforge.org
http://appscript.sourceforge.net/objc-appscript.html
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden