November 2001 Archives
My only concern is that the front page, during slow news times (such as now), the whole front page will be nothing but new modules. :-) Still, you can filter those out of your home page, and from your daily headlines/newsletter (if you get those) by clicking Module News as an excluded topic in your preferences.
Then there's modules, Mac::AppleEvents::Simple, Mac::OSA::Simple, Mac::Glue. I am torn as to what to do with them. I suppose I should keep Mac::Glue separate, because some people might want to use it with older MacPerl. Same with the others, though those are very seldom updated at all. I'll probably keep them separate for now. Hmmmm.
I need to update the licenses in them, in any event. Since I am including them in MacPerl, I'll want them to be AL+GPL (as Perl is), whereas now they are AL-only. Another few modules bite the dust ...
use File::Find;This is why Perl needs to have so many shortcuts. This is why Perl is cool.
find(sub {
next unless/\.pm$/;
$file = $File::Find::name, $size = -s _ if -s > $size;
}, "Bourque:Applications (Mac OS 9):MacPerl Æ’:lib:");
print "$file: $size\n";
The problem: I installed iTunes 2 on a couple of machines, and I figure, hey, iTunes is based on SoundJam, so it should work the same. But they changed it so iTunes 2 returns this data in UTF-16 ("utxt"), instead of regular 8-bit text ("TEXT"). I don't have the requisite Perl modules to convert at this point, but I shouldn't need them, because there are corecion handlers in Apple events that will coerce data from one type to another.
In theory, and according to the docs, it should work fine to just do (in AppleScript):
set songname to name of current track as string
Or in Perl:
my $song = $sj->get($sj->prop(name => of => 'current track'), as => 'string');
But this wasn't working. After trying to work around it (including by just stripping the high byte, which works for my purposes
Bah. So I wasted a lot of time, but got it to work.
As Bobby McFerrin said, simple pleasures are the best. Especially when they are derived from complex technology.
[As a quick side note: the code never was rewritten from when it was first written, and it probably should be. Bleah.]
So now I am working on extending it further. You can choose a different delivery method for each kind of message (currently e-mail, web, or none). Soon you'll be able to get the daily headlines / newsletter customized to your personal preferences (don't like JonKatz stories? no problem!). Also in progress is Jabber support, so you can get instant messages sent to you. I am not sure how much I like the idea, but I think a lot of other people will like it, which is good enough.
I have had trouble debugging some things because the xSYM file for MacPerl won't open in the CodeWarrior 5.3 IDE. I reinstalled and it still didn't work. However, it does work with Apple's Power Mac Debugger, and with the CodeWarrior 5 IDE. So ... I keep two versions of the IDE around, plus the Power Mac Debugger.
And then I tried to recompile yesterday, and crashes in the linker up the wazoo. Doh; I realized later that the 5.3 MWLinkPPC was causing me problems before, and I reverted. So I reverted again. Yay.
I installed it, and the Dev Tools, on the new PowerBook on a 2GB partition, and on the old PowerBook on the single 12GB drive (so both Mac OS X 10.1 and Mac OS 9.2.1 are on the same partition). I plan on this old PowerBook being my Mac OS X box.
So far, it seems reasonable. I don't like iTunes; SoundJam MP is far better. iTunes is too dumbed down (and dumb). I did get xmms (along with gnome, XFree86, etc.) installed (using fink, a port of apt-get/dselect), but it doesn't work well yet. I need an MP3 player on this box. I spent an hour or so figuring out how to get lookupd and NetInfo configured so I could override DNS, which I would call a huge waste of time except for that now I understand NetInfo a bit better.
I can't do USB Printer Sharing with it, which is a royal pain. Also, this computer has hardware DVD decoding, and the only Apple DVD player for Mac OS X is for software decoding. Fooey!
So I can use it for development and for file serving and for MP3 playing and for general playing around ... but if I can't do USB Printer Sharing, that might stink. We'll see.
It's still much too far away for me to use as a replacement for Mac OS 9.
I got ahold of it, and it had this weird problem where it wouldn't restart. The hard drive wouldn't be recognized. I had to shut down in order to boot. Pretty soon, I couldn't even start up at all. Fooey.
So it took forever for it to get repaired (not Apple's fault, per se, but the fact that we couldn't pay for the repairs right away), and I got it back and it is working fine, except that it won't wake from sleep. It will wake from a sleep of maybe 30o seconds, but anything longer than that and the drive spins up, but no lights come on, no screen, no sound, etc. I need to force-restart to get anything. Other than that, the computer is working fine. But without being able to sleep ... it could get old fast.
The good news is that it is just like my older laptop, but faster, has better battery life, and has internal AirPort. The bad news is that it can't sleep.
Oh, and if I hit the down arrow followed quickly by the up arrow, THREE characters are produced: down, "\", and up. Why "\"? If I am holding down shift, then it is "|" instead. What the heck?