Archive for July, 2006

The human body, organ thieves, Smurf pyjamas and more non-piracy 8

The Human Body
Yesterday Mark and Emma went to the Amazing Human Body exhibition at the Perth Convention Centre. The line was between 600 and 800 people long (estimates to get in were 2 hour wait) so it was a good thing the Weatherills had booked us online tickets. We skipped straight to the head of queue. I love doing that.

The concept is that they’ve used real humans to demonstrate what we look like on the inside. As such it’s highly controversial, which was the main reason I went. I spent about 25 minutes looking at the full body speciments and that was enough for me. There was stacks and stacks of smaller exhibits, but I didn’t like the lines you had to join to get a look. I felt a little queasy but that wasn’t why I left. I just saw all I wanted to. I could understand how people that have either an interest of prior knowledge (like Emma and Dea) could spend hours there but for me that wasn’t the case. Glad I went, glad I didn’t spend too long.

Falun Gong
After the exhibition I wandered into the city and was handed a pamphlet from an old Chinese lady. It was horrifying.

The short of it is that there’s good reason to point the finger at China’s communist government with accusations of killing practitioners of Falun Gong for their organs. Do yourself a favour and spend 10 minutes reading up about it.

Koral arrives
I received my gi in the mail today from Fightgear.com.au. I also ordered a few patches (though as it’s a competiton gi it’s covered in patches already) and they threw in a calendar for free which was nice.

I tried it on and it feels really comfortable, so it’ll be great to test it out tomorrow on the mats (… and then for the state competition, and then for the national competition…)

Paying for software
On Saturday I bought SimCity 4 Deluxe Edition for the Mac, and earlier tonight I bought a copy of TextMate, a handy text editor designed for programmers.

SimCity is fun to play and is what I was looking for in a game. I’ve been playing a bit of Warcraft III lately so it makes a nice change.

Two funny things happened today 3

Firstly, Maggie called to tell me she’d wrangled a better deal for her Ford Focus. To quote her, with reference to the salesman, she was “breaking his balls”. I never thought I’d hear her say that, ever.

Secondly, I bought some software. I’m so used to “apt-get install whatever” from my Linux time that it seems really foreign. I use a wonderful little FTP program called Transmit from a cool software company, Panic.

I always claimed that I wouldn’t be a pirate when I was out of uni and could afford to actually pay. It feels rewarding to acknowledge another software house for their hard work, if that makes sense.

Session variables and PHP 0

I had a major problem this morning whereby I couldn’t log into any the Aurora sites I was editing. Adam could, which made it a problem with my machine and not the code. Sort of.

It turns out that PHP uses a default name of “PHPSESSID” (which is configurable in your php.ini) for all your sessions. This became a problem when I was editing multiple versions of Aurora, and PHP got confused.

My code used to call session_start() at the top of the index.php page, and if necessary, redirect to login.php. Likewise, login.php checks if you’re authenticated (by accessing session variables) and forwards you back to index.php if you are. It was dying on session_start(), and the solution Adam found was to name each session prior to starting it.

Hence now I call session_name(’AURORA_CLIENT’); session_start(); instead.

gnome-terminal natively on Mac OS X 0

When I first got my Mac I was disappointed that a lot of the common GNU/Unix tools I have grown to love were not available. I solved most of these problems with the installtion of Fink, which is a knock off of Debian’s package management system.

With the installation of X11 came the ability to run remote X applications and have the display local. This meant I could log into a work server and run a program and have it’s output on my Mac. I used this method to run a gnome-terminal so I didn’t lose my beloved workterm.sh functionality.

Fink has a gnome-terminal package, so after I installed the Apple XCode Developer Tools I was able to change my Fink configuration to use the unstable tree and download the source packages. I left it running over night, and when I woke up I’d downloaded the 127 other packages that are also required to run gnome-terminal (libraries mostly). I started X11 which launches an xterm, and from within the xterm I ran “gnome-terminal”. You beauty!

To make things easier I added export DISPLAY=:0.0 to my .bash_profile so that if the X server is running I can launch an application from any Terminal.app, and I don’t have to find the specific xterm. You need to ensure that you’re running a login terminal so that your .bash_profile and .bash_rc are sourced. I also changed /usr/X11R6/lib/X11/xinit/xinitrc so that lunching X11 doesn’t automatically launch an xterm, seeing as any Terminal.appl was effectively the same now.

So, being the lazy biatch that I am, I don’t want to have to go through that tedious process (OK, so it’s a few clicks and a few keystrokes, but it’s tedious) everytime I want to run the application!

There’s a wrapper script called /usr/bin/open-x11 which is used to launch the X server before starting any X11 applications. I already have workterm.sh, but open-x11 didn’t like multiple parameters, like this:

open-x11 workterm.sh prime

I hard-coded a workterm_prime.sh to get around this. Next up I saved a default Terminal.app configuration (File, Save As) and then edited the XML file, adding an ExecutionString of open-x11 /Users/mlambie/bin/workterm_prime.sh; exit;. This was saved as workterm_prime.term, and double-clicking it opens a Terminal.app briefly, launches my workterm.sh inside a gnome-terminal. As Quagmire would say, “All-right!”

The only thing missing was a pretty icon. I can drag the .term file onto the dock, but I need it to look good, right? Enter Mr. Gedeon Maheux and his Transformers icon sets (one, two). To change the icon simply copy (Apple-C) one to the clipboard, then Get Info the target and click on the icon in the top left. It changes for you like magic.

workterm prime

One-click, gnome-terminal/workterm into our development server. Finally, I feel at home.

New gi 12

MKM BlueI’m heading to Melbourne in September for the Machado Nationals and will be doing a lot of grappling (and some snowboarding too) without having regular access to a washing machine.

This spells (smells) disaster. To ready myself I’ve bought another gi.

I was considering either an Atama or a Koral, with both appearing popular at my club and with internet reviewers, and in the end settled on a Koral MKM competition gi. Plus it’s blue.

I bought it online at www.fightgear.com.au for $230, and postage is another $10. I thought it might be worthwhile getting some gear from the States, but postage would be a killer. There was talk (or rather a request) that our friend from San Diego might be able to bring something over for me, but Deana’s fallen off the face of the Earth and I don’t think she’ll be coming to Perth these school holidays. Or she’s just avoiding our calls… but that’s another post entirely.

« Previous PageNext Page »