AppleScript + iTunes + iChat

I ran across this nifty little blog post that lets you control a remote Mac’s iTunes via iChat. I decided to customize the script a bit and added a way to search for songs. Here’s my addition to the stock AppleScript:

else if (theMessage begins with "song " and theMessage is not "song ")
     or (theMessage begins with "s " and theMessage is not "s ") then

    set cLength to (count (first word of theMessage)) + 1
    set query to texts cLength thru -1 of theMessage

    tell application "iTunes"
        set theSongs to (search playlist "Library" for query)
        try
            set songID to persistent ID of (item 1 in theSongs)
            play (first track of (get some playlist whose special kind is Music)
                 whose persistent ID = songID)
            set theResponse to "Playing song request. "
        on error
            set theResponse to "Did not find any songs. "
        end try

    end tell

    set theResponse to theResponse & getCurrentiTunesTrack()

I also added “aliases” to the previous and next commands (“p” and “n” respectively), but that was pretty trivial, so I won’t include it here. This is the first AppleScript I’ve written, so I’m probably making some noobish mistakes, but it was pretty cool. Now I can chat with my Mac Mini and tell it what to play!

AppleScript/iTunes/iChat

The monster and fan one

I mentioned this earlier, but I went to the monster shoot at Carolee and Christopher’s. Then, I went to Home Depot and got a ceiling fan for my living room that Mark and Andrew helped install, which turned out to be quite an effort since we had to rewrite some switches. Later, we played a bit of Serious Sam: The Second Encounter. That game is so crazy, but oh so awesome.

We had a discussion about comics and super-hero movies. I haven’t been into the comic world much, but apparently both Marvel and DC have severely messed up universes now. DC just loves their ridiculous “multiverses” where they have huge story-arcs that aren’t entertaining at all due to confusing “timelines” just to explain away inconsistencies. I stopped reading when they had their stupid “Infinite Crisis” and came out with characters such as Superboy-Prime. Whose bright idea was it to dilute the Superman character by creating a whole ton of other versions of him and make some of them bad? Superboy-Prime just sounds really lame, too. How in the world is a kid or comic new-comer supposed to get into these plots when you have to have a huge diagram just to know what’s going on?

Marvel, apparently, decided to throw away a bunch of plot as well by just saying “oh, these super heroes? they were actually aliens for the past few years.” Sigh. Oh yeah, and reviving “dead” characters isn’t uncommon in comics, but the recent Captain America one is just ridiculous. That bullet that apparently killed him? Oh yeah, no nevermind, that was actually a special bullet that transported him to another time and place. Oh really, Marvel? That makes a lot of sense. That’s what I see here… yeah, it’s Captain America being transported to another place and time.

captain-america_shot-dead

Let me treat you to this beauty of story-writing (from Wikipedia):

“Darkseid’s essence attempts to claim the Miracle Machine in a last ditch effort to defeat Superman. However, Superman sang a note at a frequency that countered Darkseid’s own vibrational frequency, shattering his essence.”

Yay! That’s just what everyone wanted Superman to have. Super-song. Here’s another character that had this power (well, kinda):

Sigh. Someone get these comic writers out of their bubble. They need some fresh air to get back to good story-telling rather than coming up with convoluted garbage.

On a WoW-related note, I logged in to finally do my Paladin quest to get Redemption. I checked my /played time and it’s at about 14 hours. Not bad for almost level 44. =)

Monster Shoot

I woke up super early (7AM, gasp!) to go to Carolee and Christopher’s place to participate in a monster shoot. I took some video with my 5D MII, which I hope will be useful (still getting used to video on it), but I also took a few still shots beforehand:

MonsterShoot-003 (by owiber)

MonsterShoot-005 (by owiber)

MonsterShoot-007 (by owiber)

MonsterShoot-008 (by owiber)

MonsterShoot-011 (by owiber)

MonsterShoot-012 (by owiber)

MonsterShoot-014 (by owiber)

MonsterShoot-018 (by owiber)

MonsterShoot-020 (by owiber)

See Flickr for more Monster Shoot photos.

The video games music one

This weekend I went to Houston with coworkers and company. I carpooled there with Ryan, Tiff, and two of Tiff’s friends. Overall, it was a nice weekend adventure, which I would have probably enjoyed more if i had played any Final Fantasy games. Luckily, there was not a lot of terrible cosplay to make me want to run away, so we were good there. A few shots from the event…

Ryan doing a little dance at the gas station:
Ballerina Ryan (by owiber)

Yay, tickets!
VGLHouston-002 (by owiber)

Blizzard Q&A:
VGLHouston-003 (by owiber)

Loitering:
VGLHouston-010 (by owiber)

On the way back, Ryan took the Heather-prescribed route and made a wrong turn somewhere so we winded up at a place called Gay Hill that had a creepy one-lane underpass. We thought we were going to get attacked by trolls, among other… creatures.

On Sunday, I finally watched the first Bring It On which was playing on TV (I have seen the other three). I also just found out on the Bring It On Wikipedia entry that there’s going to be a fifth one!

“Just a small town girl, living in a lonely world
She took the midnight train going anywhere
Just a city boy, born and raised in south Detroit
He took the midnight train going anywhere

A singer in a smokey room
A smell of wine and cheap perfume
For a smile they can share the night
It goes on and on and on and on” - Journey

Google Juice

I will occasionally Google myself to see how much Google juice I’ve got. Particularly since moving domain names from OliverWEB.com to Owiber.com, I’ve been curious how that impacts my rank. Looking at my analytics data, it seems like a frequent path from Google to my site is querying for “bazaarvoice oliver wong“ which isn’t too surprising to me. An even better search to find e-Oliver is for “owiber.”

However, I saw that a few of the top results were to pages I didn’t particularly own or care about, so I decided to make an About Oliver Wong page with an SEO friendly URL and all that jazz. I don’t mean to seem self-indulgent, but I figured I should probably have such a page to compete with the other pages out there on the internet “about me.” It was fun just brain dumping a bunch about myself. =p

Weekend’s about over with now, which included:


  • Contractors redoing house, knocking out a wall, adding a door, tiling floor, etc.

  • Diablo II LAN party with Bazaarvoice crew

  • Helped Chancy move into their new house

  • Biked over to Chancy’s (took shortcut under the railroad tracks - ~9min at an easy pace)

  • Dinner with family for belated bday/father’s day

I will now sheepishly declare that I have some Taylor Swift stuck in my head after hearing her at least a few times over the weekend due to reasons I could not control… :-) So now I feel like an adolescent girl trying to rid my crush on the team’s football star. :-(

“Drew looks at me
I fake a smile so he won’t see
What I want and I need
And everything that we should be

I’ll bet she’s beautiful
That girl he talks about
And she’s got everything
That I have to live without” - Taylor Swift

The independent one

Let’s see here, what did I do on the July 4th weekend?…

Friday:


  • Finally watered my lawn after purchasing a water hose that was actually long enough for my needs

  • Hobo Jon photo shoot!

  • Went to Plucker’s with Al

  • Refactored a bunch of backend code on Owiber.com

Saturday:


  • Chilled with Chad for a bit, including fetching some stuff to repair a really small scratch on his car
    IndependenceWeekend-001 (by owiber)

  • People trickled on over to my house as we watched Return of the Jedi on TV. Sam loves him some Jedi:
    IndependenceWeekend-003 (by owiber)

  • Mark brings us steak! We eat then watch Independence Day (woo!).
    IndependenceWeekend-002 (by owiber)

  • We go check out Chancy’s new house (Mark, Sam and I venture across the railroad tracks to discover the short-cut)
    IndependenceWeekend-004 (by owiber)

  • We chill and everyone but me plays poker as we listen to music and mess with iTunes DJ
    IndependenceWeekend-005 (by owiber)

    IndependenceWeekend-006 (by owiber)

    IndependenceWeekend-007 (by owiber)

Sunday:


  • A lot of bumming around, and watching more Weeds (Season 2) with Ochs and Chancy.

Thaaat’s it! (I think)

The owiber.com one

I think I’m going to start titling all my weekend posts with “The ____ one.” Sounds like a TV series episode naming scheme. :-)

This weekend was very much dominated by me listening to music at my house, sleeping, waking up with random website ideas, and then throwing together what you see here now. I’d call that a productive weekend. On Sunday night, Chad, Nancy, Ochs, Sam and I watched the first few episodes of season two of Weeds. I also managed to make my way to Town Lake and ran and kayaked a mile-ish.

I bought a water hose and stuff to give my lawn some loving, but never actually put it to use… well… maybe tomorrow…

I also printed out a bunch of photos and put them on my wall with magnetic photo rope I purchased from Photojojo:

photorope-001

“Maybe I’m wrong, won’t you tell me if I’m coming on too strong
This heart of mine has been hurt before, this time I wanna be sure

I’ve been waiting for a girl like you to come into my life
I’ve been waiting for a girl like you, your loving will survive
I’ve been waiting for someone new to make me feel alive
Yeah, waiting for a girl like you to come into my life” - Foreigner

Oh Saturday

Just finished running and kayaking a bit, so I’m just chilling at my place listening to music and messing around with Python/Django a bit so I can contribute to Bazaarvoice’s open sourced “TwitterVoice“ app. I think I’ve made it apparent I’m not a huge Twitter fan, but it’s a good chance to scratch my code monkey itch and gain some more experience with frameworks. If it goes well, I may use it for some future personal projects like… Friends 09 maybe (for historical reference, here are 99, 00, 01, and 04). =p

Been in a somewhat mellow introspective mood lately… but I don’t really have anything to blog about regarding that, other than to state it. :-)

I stopped by a flooring store today to look at tile and I can’t decide what I want! Arrgh!

“I close my eyes when I get too sad
I think thoughts that I know are bad
Close my eyes and I count to ten
Hope it’s over when I open them

I want the things that I had before
Like a Star Wars poster on my bedroom door
I wish I could count to ten
Make everything be wonderful again” - Everclear

The Weekend Summary

Ochs and Sam thought I made a commitment to post what I did every weekend in this post, but I don’t think I did. Regardless, I suppose it’s a decent idea, so here it is:


  • Friday: Went to Home Depot with Nancy to look at tile for my house. Needed to get a replacement light bulb and water-filter, but forgot to take note of which on both accounts.

  • Friday: Went to see Up by my lonesome. Left feeling a little post-Amelie… like I wanted to hug someone, but less “romantic” like after Amelie.

  • Saturday: Got contract work at my house (tiling, knocking out a wall, etc.) estimated

  • Saturday: Peter moved out, so I vacuumed the room after he left… I then went to clean up some other parts of the house since I was already in the mode.

  • Saturday: Watched season one of Weeds with Chad and Nancy after bumming around listening to music at my place, getting not very satisfactory burgers at Fuddruckers and a now almost customary weekend double iced alamocha at Texpresso.

  • Sunday: Went to Lowes and picked up the light bulb and water filter I needed. Took a quick glance at tile.

  • Sunday: Went home and got a hair cut (thanks, Mom!). My doggy Orbit is getting old. =(

  • Sunday: Hung out with Ochs & Sam at Burnet Sonic for a while at night.

No pictures this week, though. Adios!


Mum mum mum mah
Mum mum mum mah

I wanna hold em’ like they do in Texas plays,
Fold em’ let em’ hit me, raise it, baby stay with me, (I love it)
Luck and intuition play the cards with spades to start,
And after he’s been hooked I’ll play the one that’s on his heart - Lady GaGa