Blogs

Live-Tweeting the WWDC Keynote

June 7, 2010 - 12:00pm

Head over to Twitter for some live coverage of the keynote today.

I was writing some shell scripts the other day and I had to find which OS X version I was running and based on the OS X version I was trying to install my application. So this is a small and easy tip as to how you can find out the OS X verison using the default command.


OS_VERSION=`/usr/bin/defaults read “$3/System/Library/CoreServices/SystemVersion” ProductVersion`
echo “$OS_VERSION”

You can also get more specific if you want only the major version or the minor version by piping the OS_VERSION to ‘cut’ command by specifing the fields.


OS_MAJOR_VERSION=`echo $osversion | cut -f2 -d’.’`
OS_MINOR_VERSION=`echo $osversion | cut -f3 -d’.’`

This has been floating around the Internet but I felt the need to say that:

  1. I tried it.
  1. It works.

The German site BenM posted a few days ago that it had written up some configurations for iPhone OS 3.0 that enable tethering on most carriers, whether they wanted it done or not. This is a pretty neat hack for several reasons:

  • It does not require a jailbreak or other real hacks.
  • It’s easily removed via the iPhone’s interface.
  • It’s just quite smart.

So, here’s how to do it:There's more »

  1. Go to the following site from your phone: help.BenM.at
  1. Find the page for your country and then the carrier you are using.

I have a need. I have to make latitude/longitude (LL) points more reasonable and usable by humans.

This is quite possibly one of the more difficult tasks out there right now, and also one of the most-outsourced as a result. The reason is simple: the dataset is huge and the calculations quite intensive.

In order to get information about an LL, like the city, state, county, zip code, or (most complicated) street and approximate address, you have to do some geometric math. Let’s start with counties, since that happened to be the first thing I had some success in. You get a list of counties and their borders as geometric shapes. You then take a range from the LL and find all polygons that touch that range. Then you further filter to the one that point is in.There's more »

Since I use Mercurial and it doesn’t have Xcode integration, I find that I’ll have added classes or whatnot and they will not have been added to the repository and I’ll forget about them come checkin time. That’s bad.

So I thought about ways to remedy this, and after describing the issue to myself, the issue was clear. “When I add new files to the directory, it should run hg add on the files.” Well, when when we need to do something when a directory changes, we use launchd yes? Yes.

So I made a launchd item that ran a script any time my specific repository changed. Since this is just for yourself, it can go in ~/Library/LaunchAgents. The item should set the current and working directories to the repository so the context of the hg commands is proper.There's more »

First Look: MacBook Pro (Late 2008)

October 16, 2008 - 2:18am

The new MacBook Pros are a substantial change from the previous generation of MacBook Pros, but it’s hard to call them an upgrade, in my opinion. I’ve been using Macs for a couple of decades now and when I think of the word “upgrade” I tend to think of a notably faster processor, more features, and other goodies that make it scream “hey, this is what you have, but better!” The new MacBook Pros don’t really scream upgrade.

They scream redesign.

This isn’t the old MacBook Pro on any level. The only thing they have in common is the case material and the size of the unit. Other than that, this is a whole new computer in every measurable aspect: the screen is better, the keyboard has changed, the case is sleeker, the port layout is cleaner, the trackpad is …There's more »

Can i install my Leopard OS onto my PC?

Yes. The current solution is to use a piece of software called simply “PC-EFI” that emulates a Mac firmware environment. There’s some instructions out there already for how to get this done.

Hello, I am looking for information regarding how to boot a iBook,G4, with linux on a USB flash drive…

You cannot boot a G4 iBook from a USB drive of any kind — only FireWire or internal drives.

On my iBook G4 14’ when I run openSUSE 10.3 I noticed (for some time now) the white led blinks when the hard drive is accessed.There's more »

Well, it’s about damned time.

I’ve been wanting to write up some iPhone dev pieces for a while but pushed the idea aside because of the SDK NDA issue. Well, Apple’s finally come to their senses and removed the NDA so that developers can actually form a community now.

This is one of two major issues that have made developers uncertain about writing for the iPhone platform, what with Android coming very soon now. The other issue, which Apple has yet to deal with, is the rejection of applications based on unreleased criteria.There's more »

Background

The introduction of the MagSafe connector for MacBooks and MacBook Pros was NOT good news for users of iGo or Kensington airline/car/boat power supplies. Neither manufacturer has yet come out with a MagSafe tip, for reasons probably related to Apple’s patent.

This hint describes a simple method of using an iGo power supply with a MacBook. Some simple soldering is required, and following these instructions will obviously invalidate your warranty for both the power supply and your MacBook. The author takes no responsibility whatsoever for any damage caused!

If you already have an iGo (mine came with tip 4 included), this hint will set you back £2.08.

The principle is very simple: Insert an in-line plug and socket into the cable of the original Mac power supply.There's more »

Ever get that lovely “overlapped extent allocation” or “missing extent” error when checking your drive in Disk Utility? Notice how it never gets repaired when you repair the disk? There’s a reason: it’s technically irreparable.

The extents that the error is referring to are the file fragments on your drive. There’s a special catalog file called the extents B-tree (this is also sometimes referred to as the extents or extents overflow file) that holds all of the information on which files have which fragments on the disk. Each fragment is an extent. When you have a missing extent then you have a record that states that there are a certain number of extents for a file, but the known extents are too few for that file.There's more »

Syndicate content