[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] New User's MacPerl Questions



At 10:10 PM -0400 9/15/98, David Rouse wrote:
>I've been recomended MacPerl by the AppleScript list, after they heard what I
>was trying to do with AppleScript -- conversion of text files (lots of
>them) to
>HTML encoding.

Might even have been me that referred you.

> I looked through this list's archives before signing up, but
>there are already a few questions I have.
>
>1) Is there an extension or AppleScript for BBEdit to run/syntax check MacPerl
>scripts that I'm editing in BBEdit?

Did you try Bare Bones' web site?
http://web.barebones.com/support/plugins.html

>
>2) My UNIX-centric learning Perl book uses something like system('date')
>get the
>date from the machine. When I do this I always get a -1. I guess my
>question is
>-- where in the documentation does it cover finding the date and assigning
>it to
>a variable?

The best (and not just because it's the only) book on MacPerl is
MacPerl: Power and Ease - you can find it at any quality local bookstore, or
here http://www.ptf.com/macperl/ptf_book/.

But, you should also look in your unix-centrist book for a function called
'localtime'.  It's what they should be using instead of system('date').

>
>3) Many of the text files I'll be encoding into HTML will have special Mac
>characters like option-8 bullets and long dashes. What is the best way to
>tackle
>this?

As Mike Pasini said, it's not a problem.  Just use them like you would any
other string literal.

>
>4) I'd like to be able to 'watch' a folder (like in AS with an idle timer), is
>this a MacPerl question, or should I just buy the next book in that
>UNIX-centric
>Perl series?

It is a MacPerl question.  It should be possible - unfortunatly I'm not the
guy to tell you how (Mac guru, Perl newbie).

>
>What I'm trying to do, by the way, is help my newspaper export stories and
>classified ads to the web. Classified ads will already be sorta in HTML, the
>news stories will be in XTAGs (Quark's text markup). One of the cool
>things I'd
>like to do is find in-the-news names and insert a link that jumps to a
>short bio
>and picture of the person, place or thing. But first, naturally, I need to get
>my head around Perl.
>

Good Luck.  And maybe Mike's script is what you need, and you don't have to
look any further.

-Jefferson R. Lowrey
Systems Programmer
Sells Printing Company



***** Want to unsubscribe from this list?
***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch