Leopard Restraint

I’m as excited as anyone about Leopard. In particular, Time Machine and Spaces. Time Machine because backups have to be automated and I’ve never investigated the options. Spaces because virtual desktop is the one thing I really, really, miss from Linux. I also have hopes that Spotlight will actually be worth using. And I know there will be tons of the little things which seem pointless in isolation, but make a superb impact overall.

However, I will not be upgrading until at least the first significant patch. Leopard early adopters suffer for the rest of us. I salute you guys for your assistance in making the platform more stable. Me, I’m going to continue using Tiger until the “blue screen” problem is a thing of the past, Skype works, and MOST IMPORTANT, Rails works without the hassle I went through on Tiger when it first came out (it wasn’t very funny).

Apple and Google both have a policy of secrecy, which has been highly successful in an era where the common mantra is openness and transparency. It works fine for both of them, but it’s better for Google, where the barrier to usage is low. For Apple, there’s always a risk of charging hundreds or thousands for something that turns out to be seriously broken. They’ve been fine to date, mostly due to the zeal of the Apple crowd, as well as what must be some very savvy development and testing processes. While it works fine for Apple, I as an individual user make sure to protect myself from the risk of early releases.

The sweet spot for me and Apple is being a late Early Adopter – that’s the right balance between the increased productivity from new features and the loss of productivity from using an OS that’s been sent into the wild sans beta test. I may be a fanboy, but you won’t see me queuing up in Regent St for a week. I’ve gotten by without Leopard for the some decades; I can wait another month.

How to share your Mac desktop (OSX 10.4 – Tiger)

I had my first remote desktop sharing experience on a Mac yesterday. I needed to run a demo on my Mac for a remote user, and it turned out to be not all too challenging, once I worked out what software was required. All of it free and painless to set up for both parties.

Here’s how you do it. “You” are the one sharing your desktop, i.e. showing what’s on your screen to someone else on the net. “The Viewer” is the someone else viewing your desktop.

Enable Remote Desktop Sharing on your Mac

Fortunately, this is free and built into Tiger – you just need to be enable it.

  • System Preferences | Sharing | Apple Remote Desktop. Tick this option.
  • Click on Access Privileges
  • Tick “Observe”, “Show when being observed”, “Guests may request permission to control screen”, and “VNC viewers may control screen with password”
  • Enter the password next to the last of these options, e.g. we’ll assume it’s “easy2guess”.

Set Up Port Forwarding on your Mac

You’re probably running this behind your router, so log into your router and forward incoming TCP port 5900 to your PC.

Port forwarding is a whole topic in itself and if you don’t know anything about it, you’ll need to read up. Very briefly, it means that when a request comes into your router which sits at the front of your LAN, the router knows which PC to send it to. To set up port forwarding on your router, you’ll need to know: (a) how to log into your router and change port forwarding options; (b) the local IP number of the machine you want to share – run ipconfig or ifconfig and look for a number like 192.168.something or 10.0.something, or look at your router’s output; (c) the port number – I just told you that. (It’s usually configured as a range, so just use 5900-5900.)

Well done. Your machine is now ready to be shared.

Viewer Installs a VNC Client

The Viewer will need to install a VNC client. If they’re using a Mac, may I suggest Chicken of the VNC, a fine open-source product whose merit extends beyond its moniker. Worked for me anyway. Detailed chicken review here. As with most reviews though, it doesn’t say much about the big picture and what happens on the server, hence the article you’re reading.

Pass on your External IP Number to Viewer

Just prior to connecting, pass your external IP number to the Viewer by phone or email. Fastest way to determine it is to visit WhatsMyIP.org. It’s also in your router app somewhere.

Viewer Connects to Your Machine

The Viewer runs the VNC client and enters your IP number (with chicken, run Open Connection from the connection menu). They’ll also need to enter the password you set up earlier (which we made “easy2guess” above). And now they can see your site.

Tweak Settings

If it’s slow, the Viewer will hopefully be able to tweak the options of the VNC client they’re running, e.g. reducing the resolution or the number of colours.

Shut it Down

When your session is finished, remember to turn sharing off, which you can do via the System Prefs again or the toolbar.

Final Caveat

VNC isn’t encrypted by default, so be aware that what you share with the Viewer is as vulnerable to third-party access as email and other internet traffic. The fact you use a password may give some people a false sense of security.

Tabbing, Terminals, and Apple’s Popup Bug

Popup Bug

The most annoying thing about programming in OSX has now been fixed, finally. For years now, every time I want to switch tasks to an XTerm (under X11), it doesn’t work the first time. I have to choose it in the task switcher, then go back to my app, then go back to the XTerm (Alt-Tab,left a few times,Alt-Tab,right,Alt-Tab,left a few times) Many others have had this problem in the past too (Mike Kruckenberg, Crazy Bob). Some have reported it fixed in the past too, but it never worked for me, until today. THANKYOU!

Well, some of the annoying, tedious, tasks become subsconscious after a while, but not this one. It was way too frustrating to morph into a neurological shell script. I am now 10% more productive and 100% more satisfied with programming in OSX. And more so once I switch my Rails dev over from Eclipse (+Rail plugins) to the shiny new IntelliJ Rails setup. (IntelliJ+Rails+OSX==Could it get any easier?)


Actually, I’d like to be using Multiterm – tabbed terminals makes so much more sense, and it would also have overcome the crippling popup problem that no longer cripples. But, like Apple’s own ITerm, it’s dog-slow. Very odd to have a visible delay on a terminal in 2007, as if you were hammering a VT100 in 1977, but yes that’s what happens. L..e…t..t.e…r..s s…h…o.w… …u..p ..t…o..o ..l..a.t….e :..-…). You can read here about the slowness of OSX terminal apps that is as astounding as it is frustrating.

I will also take this opportunity to start using the “screen” utility, a command-line shell switcher. I just now realised why I’ve always overlooked it: It was banned years ago at uni due to resource constraints. That’s when I started working with Unix, so I always ignored screen, but it seems to be the only realistic way to run multiple sessions in a single term window, on OSX.


The Diggnation guys were joking a while ago about how just saying something has a “tabbed interface” makes it cool nowadays. Fact is, tabs are pretty cool and applicable in many situations. Here’s an example. I have a new phone – Orange SPV M700 (which is about anything you could ever ask for in a smartphone, awesome!!!) – and installed Opera as it renders better and more reliably than IE. One extra benefit is tabbing – yes, this mobile edition of Opera has tabs, standing out from other mobile browsers just like its grandaddy on the desktop years ago (which was then bolted onto Moz/FF/Safari and finally IE7). Well, I was surfing the web while on the tube, browsing DiggRiver, and about to lose signal as the train went underground, but no worries, open up 5 or 6 new tabs in a few seconds, they all loaded, and I had enough content away from the signal. Windows Mobile has a nice popup menu feature where you hold down the stylus a second or so, so you hold the stylus down on a link and Opera gives you a popup menu for that link, including Open in New Tab. Sweet.

powered by performancing firefox

The Switch to Linux Begins?

A couple of high-profile bloggers (via Dion) make the switch from Apple to Linux and O’Reilly Radar wonders if it’s the starty of a trend. While I prefer working with Apple, I’m nonetheless an Ubuntu fan so I certainly hope this trend picks up. However, I wonder if people know what they’re getting into. In both of the Switch articles by Cory Doctorow and Mark Pilgrim, the authors focus on the reasons for moving away (more hardware bang for your buck, using mostly open-source anyway, various misgivings with Apple softtware), but neither actually explains what sort of experience they’ve had with Ubuntu and how they’ll cope with the issues that inevitably arise. Okay, so these are both insanely smart guys and can deal with it, but if others follow, they might be sorry.

The fact is, Ubuntu takes Linux a step closer to the user-friendly desktop it should be, BUT it’s still a far cry from the ease you can expect from an Apple. I’ve been using Linux for 13 years, and if there’s one golden rule that’s always applied, it’s this: At least one thing will always fail. It could be wifi, it could be X, it will probably be power management on a laptop, it could be running Skype at the same time as ITunes. Whatever it is, it will require a decision: Do I spend 2+ hours trawling for solutions and ultimately recompiling the kernel on the dubious assumption that it will resolve the issue and not break anything else in the process, or do I just live with the pain. As a student, the answer was often the former; in the real world, it’s inevitably the latter. Even with a modern, fairly Linux-friendly laptop (Toshiba Satellite Pro), Ubuntu ?5.05 still led to the aforementioned audio and power management issues, and most Ubuntu switchers are likely to come across similar issues.

Furthermore, though Mark Pilgrim complains about ITunes (as have I) and uses mostly open-source stuff available on Linux, there’s still a lot of software missing from the modern Linux desktop. You will suffer with inferior, incompatible, versions of Real and Flash, household apps like Skype will trail even further behind than on Apple, and you will end up with clumsy – if well-intentioned – impersonations of the finely polished apps you use every day (yep, such as ITunes. I’m not even going to mention the Gimp.) In addition, more specialised software will be much harder to come by. For instance, I recently needed some screencasting software, and, while options on the Mac aren’t great, they’re certainly more appealing than under Linux, where there are so many possible hardware combinations it may not work anyway. If there is useful Linux software that fits a niche, there’s a very good chance it runs under Apple too.

I love working on OSX due to the underlying command line, but I’m no Cult Of Mac guy. There’s a lot of silly things about the Mac, like hanging on to one-button touchpads, resizing windows from one corner, etc. Some might see them as cute eccentricities, some may say I don’t get the zen of Apple, whatever. All I can see is that these “features” are pretty much a 22-year old joke, though nothing I can’t live with. In addition, DarwinPorts and Fink aren’t perfect; I’ve never got gnome-terminal working with fonts that I can actually see. Furthermore, Apple support sucks in my experience. I recently suffered from a pathetic support incident involving around five prolonged calls to an offshore call centre, no resolution, and will now require some correspondence with the legal department. So I’m all for a ?revival of Linux among the uber-geeks. I’m just saying: I hope you know what you’re getting into. Cory says he’ll be blogging the experience, which will be interesting to watch.

Installing Linux? Some Tips For Switching From Apple To Linux

Here are some tips if you’re thinking of switching to Linux:

  • Go with Ubuntu. Sorry, no choice here if you’re new to Linux. Ubuntu right now is the clear choice for a standard Linux desktop setup. Best hardware compatibility, good support wiki, excellent hardware compatibility apparently due to its networked feedback facility, the power of apt-get (which beats RPM hands-down) and the most important thing: a Live distro (next point).
  • Try the Live distro first (The killer app of Ubuntu is that it supports both live and installed Linux.) Run the live distro, see how it handles your hardware, kick the tyres a bit to pinpoint the things that don’t work (see above – there will always be at least one thing that doesn’t work), and decide whether you can live with that.
  • Go for an Express installation When you proceed to install, it’s easy to go control-freak and spend hours setting things up. The problem with that is you often have to do a reinstall for one reason or another. Modern Linux systems make it easy enough to change settings later on, as well as install new software, so there’s no need to do it upfront.
  • Buy the right hardware So many people encounter problems with Linux because they’re using the wrong hardware, often hardware that is notoriously bad on Linux. Whenever you buy a laptop, a card, etc that you intend to run Linux on, do your homework first and note that manufacturers hardly ever advertise they are Linux-compatible (as they’re probably worried they’ll be obliged to support it). Google is your friend. Your friend running Linux is your friend. If you’re willing to pay for it, Macbooks are an appealing choice for for running Linux on. They’re reasonably priced, since Apple is now aiming for the mass market, and they are very standardised, which is a huge benefit when it comes to Linux. Isn’t it ironic?

OSX Screenshot Script

Let’s say you wanted to capture a few images for a fade effect, which means you need a sequence of rapid screenshots. Here’s a script I’ve been using:

i=0 ; while [ 1 ] ; do i=expr $i + 1 ; screencapture -C $i.png ; sleep 0.1; done

Hit ctrl-c to kill it, then view the sequence with gqview or something. Then use the very cool Flysketch to grab the same position each time. Caveat: The 0.1 millisecond interval is optimistic, the powerbook seems to handle only about 3 pics per second.

The camera sound effect helps a lot as you know precisely which instant got taken and also creates the requisite fashion shoot ambience.

Here’s a sequence with a fade effect (One-Second Spotlight) from Everybody’s favourite fade effect website.

Image Hosted by ImageShack.us
Image Hosted by ImageShack.us

Image Hosted by ImageShack.us

The alternative would be to record it as a screencast and pick out the frames. I was using Wink under Linux, but haven’t looked into OSX tools, any suggestions?