Archive for October, 2015

It’s the Ecosystem, Stupid

Tuesday, October 27th, 2015

Those who analyze Apple stock seem to assume that Apple sells a bunch of unrelated hardware and software products. They assume that if the competition, for example, comes out with a better smart phone at a lower price, then it’s all over for Apple. Thus Apple is valued as if it is always teetering on the edge of bankruptcy. They must constantly create mind-blowing new products. Fail to do so even once, and they are out of business.

This is incredibly stupid. Apple’s product is the entire unified ecosystem created by the combination of all of its hardware and software. Apple’s ecosystem is like the Hotel California. You can check out any time you like, but you can never leave. Once sucked in, you will purchase new Apple products annually for the rest of your life, and your children will do the same after you are gone. The number of people living in the Apple world only increases. The potential market is every man, woman, and child on planet Earth.

I have a MacBook Pro. My wife has a MacBook Pro. We both have iPhones. I have an iPad. She has an iPad mini. We don’t have Apple watches yet, but we probably will by next year. We also have an Apple Time Capsule and an Apple TV, and a couple of 27″ Apple monitors. We’re not going anywhere.

So far this year, we have bought new iPhones, the iPad mini, and her new MacBook Pro, somewhere around $4,000 worth. And we just ordered the new Apple TV. Next year, we’ll probably get the watches, and it’ll be time to finally upgrade my old iPad 2. Another $1,300 or so. Oh yeah, and we’ll probably get new phones as well. And so it goes. Forever. And I’m not even talking about cars.

Apple is one of the most, if not the most, secure bets of any company in the world, and it is treated by the analysts as one of the shakiest investments anywhere. I actually read an article making the point that if Apple sells too many iPhones, it will be bad news, because they will be moving that much closer to market saturation.

Apple announces earnings this evening. I sure hope they didn’t sell too many iPhones.

Apple Mail account names

Monday, October 12th, 2015

The Mail application in El Capitan made a few changes. It moved all the email files and folders out of the V2 directory into the V3 directory. It also got rid of the Accounts.plist file that previously contained the display names for all of the Mail email accounts. And it changed the names of the email account folders in /Users/[your home folder]/Library/Mail/v3 from meaningful labels to meaningless hexidecimal character strings.

So I sent this tech support query to Apple:

I am the developer of MailSteward, an email management system that archives email into a relational database. Before El Capitan, I was able to access the email account display names from a file named Accounts.plist. That file no longer exists and I have been unable to find any source for those display names. As a result MailSteward is now using the folder names of the accounts in the V3 directory. However, with new accounts in El Capitan, these folder names are just strings of hexadecimal characters. Is there any way I can find the display names to associate with these hex account ids?

Apple replied:

…Our engineers have reviewed your request and have concluded that there is no supported way to achieve the desired functionality given the currently shipping system configureations…

It took awhile, but I finally figured out a way to provide meaningful display names for the Apple Mail email accounts listed in the MailSteward settings. Here is a piece of the objective C code that does the job, after first finding an email file in either the inbox or sent folders, from which I can extract an email address:

if ( [myFilePath containsString:@”Sent”] ) {
if ( [emailBlob containsString:@”Return-path: “] ) {
aRange = [emailBlob rangeOfString:@”Return-path: “];
aRange.location += 13;
} else {
aRange = [emailBlob rangeOfString:@”From: “];
aRange.location += 6;
} else {
if ( [emailBlob containsString:@”Envelope-to: “] ) {
aRange = [emailBlob rangeOfString:@”Envelope-to: “];
aRange.location += 13;
} else {
aRange = [emailBlob rangeOfString:@”To: “];
aRange.location += 4;
if ( aRange.length && [myFilePath hasSuffix:@”.emlx”] ) {
aRange.length = [emailBlob length] – aRange.location;
[myAcctName setString:[emailBlob substringWithRange:aRange]];
aRange.length = [myAcctName rangeOfString:@”\n”].location;
aRange.location = 0;
[myAcctName setString:[myAcctName substringWithRange:aRange]];
[myAcctName replaceOccurrencesOfString:@”\%40″ withString:@”@” options:0 range:NSMakeRange(0, [myAcctName length])];
if ( [myFilePath containsString:@”[Gmail]”] ) {
[myAcctName setString:@”Gmail”];