Category: <span>Development</span>

A shout out to Brent Simmons regarding his take on code formatting style.

Personally I tend to agree with Brent that opening braces at the end of lines is easier to read. Perhaps this comes from the fact that he and I both spent lots of time writing UserTalk code in Frontier’s outliner.

Typically code written in the outliner didn’t have curly braces at all – code blocks were defined by indentation, though occasionally we’d use braces on a single line:

Multi-line example:

Single-line example:

But when you take the same code and copy/paste it from the outliner into a text document (or save the script to a text file), you get this from the multi-line example above:

Note the left-brace at the end of the first and third line. (The same text could be pasted back into the outliner to get the braces-free, indented version.)

Another reason I like the brace at the end of the line is that when you collapse a block in Xcode, the whole block lands on a single line in the editor, instead of on two lines. Personally I find this a lot less distracting than having two lines for every collapsed block, and being an outliner guy, I use expand/collapse in Xcode quite a bit.

Anyway, just a thought…

Ps. I totally agree with Brent that consistency is more important than the specific style rules.

Development

I’m super-late to this but wanted to shoot the link out there since I’ve also written about this before. Over on evilbrainjono.net, acknowledgment that Firefox updates are driving users away from the browser.

In particular, I love this paragraph:

“I’ve been thinking a lot about the fundamental disconnect between the developers and the users. I think it comes down to: Software developers have a perverse habit of thinking of updates/new releases as a good thing.”

[Edit] Jono also has a follow-up post with some juicy bits. My favorite:

“… Let me revise my statement: Rarely is a UI change such a big improvement that the efficiency gain from adopting it outweighs the efficiency loss from relearning. Designers tend to overestimate the benefit of a change and underestimate the importance of habituation. That’s what I was trying to say.

“Look down at your hands. Are you using a DVORAK keyboard? Why not? It’s theoretically more efficient, right?”

Development Open Source Web

PowerBook_G4_17.jpg:
I’ve had a 17-inch PowerBook G4 sitting around gathering dust for a few years. It was my development machine for a couple of years at UserLand, until I got a quad-core G5 tower machine, at which point it became my field-recording rig.

I’ve decided to resurrect it as an Ubuntu machine for mucking around with modern Linux tools, which it should run just fine. (I’ve been playing with Linux for years in various flavors, but mostly server machines with no GUI, and it’s time I tried out a modern Linux OS.)

So the first step is to image the drive. It would be nice if I’d been rigorous about backing this machine up, but I hadn’t. It’s got years of work on it, all of which exists… somewhere… but if I ever need to go back and find something that didn’t make it into my working directories on the G5 tower, the chances of my finding it are slim-to-none. Enter SuperDuper!

SuperDuper.png: I considered using rsync to mirror my files onto either my Synology NAS, or my G5, but that would have made an assumption that I actually knew what files I might need in the future. Instead I decided to create a bootable disk image (dmg format). If I ever need to restore this machine I can, and if I just want to find a file, I can mount the disk image and navigate it just like the contents of the original disk.

SuperDuper! is running now, and will take about four hours to creat the image on my NAS.

Next, I need to create an Ubuntu install disc. This might be a challenge, since it’s an older machine with a PPC processor (not Intel), and I haven’t fully investigated the challenges around graphics, sound and network drivers. With any luck it shouldn’t be too difficult to get working, since lots of Linux geek types have had this or similar laptops at some point. It’s going to have to be a 32-bit install, and the machine is single-CPU, single-core, so figuring out what kernel to use for multi-processor or 64-bit support shouldn’t be an issue.

PS: Found a starting point for Ubuntu 11.10 “Oneiric Ocelot” for this machine. The Minimal CD should be a good start…

Development Open Source