It’s the Ecosystem, Stupid

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

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”];

The Mac App Store Blues

June 4th, 2012

We here at Pubblog have a number of products on the Mac App Store. It’s been great. It’s a great idea. Thank you Apple for providing this universal, integrated, easy to use, safe venue for independent software developers.

We also applaud The new Mountain Lion requirements for a developer certificate, which means that everyone, including Apple, knows who you are, and if your app does anything bad, it can be purged from everyone’s computer. This is an excellent idea, and one we are happy to comply with.

However, we have serious problems with the new, as of June 1st, sandboxing rules on the Mac App Store.

One of our products is called FileMyFiles. It has been on the Mac App Store pretty much from the beginning. One of its features is the ability to remove an application along with all of the files related to that application. Of course you must have Administrator privileges in order for it to work. This feature was rejected by the Mac App Store, so the App Store version does not have it. However the slightly more expensive version sold on the FileMyFiles web site still does include this feature.

There is also a feature for making file name and folder name changes to a collection of files and folders. Recently a bug that affected changing spaces to other characters, such as underscores and periods, was reported by a user. The bug was quickly fixed and tested, and a new version was loaded on the Pubblog Store, and submitted to the Mac App Store.

A week later, this bug fix to the App Store version was rejected, because of yet another FileMyFiles feature. The feature from which File My Files derives its name enables a user to organize all of the files in a particular folder, into separate subfolders according to file type. The user chooses the folder to organize, and the program then creates whatever subfolders are needed and moves the files into the appropriate subfolder. You can also unfile your files, which will put them all back where they came from and remove the subfolders that were created.

The bug-fixed app was rejected because the user does not specifically ask, via a standard Save As dialog, to create each of the file type subfolders, or to remove said folders. This, even though the user has already specifically requested that File My Files perform its tasks on a particular folder that the user has chosen.

This is a rule that is part of the new sandboxing requirements. It seems they have been put into effect, not only for new apps, but for existing App Store bug fix releases. However, all previous bug fixes have been accepted, and the current version of FileMyFiles with the unfixed bug has been allowed to remain in the store so far.

If this continues to be the policy, we will be forced to remove FileMyFiles from the App Store rather than have a version out there with a bug we are not allowed to fix.

Another app, MailSteward, uses the SQLite database engine, which creates a journal file as a database is being updated. Since the user has not authorized the creation of this file, even though it is in the same location as the user has chosen for the database file, it violates the sandboxing rules. So that app too cannot exist on the app store.

A new unreleased app downloads thousands of files into a folder chosen by the user. The sandboxing rules dictate that the user must authorize the downloading of each of the thousands of files, which would make the app useless. So this app also cannot be in the app store.

In short it looks like the new sandboxing rules will eliminate the majority of utility type programs which have anything to do with the file system. Or the app must be crippled and/or given a dumbed down user interface, for which the developer, not Apple, will be blamed.

I do not understand how these Mac App Store policies serve the customer, or Apple, or the developer, in any way.

Make Xcode 3.2.6 Create Universal Binary Mac Applications

May 4th, 2011

Before Xcode 3.2.6, the default build configuration for an application was a universal binary that ran on both PPC and Intel Macs. Xcode 3.2.6, however, has a default of Intel only, and there is no universal binary option in the drop-down in the Build tab of the Project Settings.

When I did a new release of MailSteward recently, using Xcode 3.2.6 for the first time, the result, unbeknownst to me, was a 32 bit Intel only build, not a universal binary build. I didn’t expect Xcode to secretly change my project settings, so I didn’t notice what had happened.

Here is how to fix it. Select Other… from the Architectures drop-down in the Build tab of your Project Settings. You can then add your own architecture, as in this screen shot:


Your Architectures Setting will now look like this:


Then clean all targets and do a new build and the result will be a universal binary application.

Snow Leopard breaks MySQL

August 31st, 2009

If you already have a MySQL installation on your Mac Leopard system, upgrading to Snow Leopard causes a minor problem.

When the MySQL database server software is installed, it creates a directory, in the /usr/local/ directory, with a name that contains the version information, for example, mysql-5.1.37-osx10.5-x86. It also creates a symbolic link to that directory that looks like this: mysql -> mysql-5.1.37-osx10.5-x86

The symbolic link is simply a short name that points to the actual directory with the long name, similar to a Mac OS X alias. For some reason, when Snow Leopard is installed, it wipes out this symbolic link. The long-named directory and all of its contents remain untouched, but there is no longer the short name “mysql” pointing to it. This may prevent applications from connecting to the MySQL server. The following steps will fix the problem:

1. Open a terminal window and become the OS X system root user, by entering the ‘su’ command and then entering your system root user password. If you have not already enabled your system root user, here is how to do it:

  • Choose Apple menu > System Preferences and click Accounts.
  • Open Accounts preferences
  • Click Login Options.
  • Click either Edit or Join in the Network Account Server section.
  • Click Open Directory Utility.
  • Click the lock icon to unlock it, and then enter your administrator name and password.
  • Choose Edit > Enable Root User, and then enter a root password in the Password and Verify fields.

2. Execute the following commands on the command line:

cd /usr/local
ln -s mysql-5.1.37-osx10.5-x86 mysql

Your installation may have a different version number in the directory name, so you will have to check to see what your directory is named. You can do this by listing the contents of /usr/local with this command:


That’s all there is to it. Once this is done, you can close the terminal window. You also may have to start up the MySQL server. You can do this with the MySQL pane in Systems Preference that you installed when you installed MySQL, or you can always start up the MySQL server on the command line in a terminal window like so:

mysqld_safe &

Moving MySQL databases to a Different Location

May 1st, 2009

I decided to try to move my own MySQL database files to a different location on an external hard drive. This is for MySQL on Mac OS X 10.5. The original database files are located at /usr/local/mysql/data. Here are the steps I took:

1. Stopped the MySQL server. You can do this using the System Preferences MySQL pane, or you can do it like so:

mysqladmin -p shutdown

Then give it your MySQL root user password and the MySQL server will shut down.

2. Became the system root user.

3. copied the /usr/local/mysql/data directory and all of its files and subdirectories to the new location at /Volumes/Elements1TB/mydbs/ like so:

cd /Volumes/Elements1TB/mydbs
cp -R /usr/local/mysql/data .

4. Added a line to my /etc/my.cnf file. My /etc/my.cnf file now looks like this:


5. Navigated to the /Volumes/Elements1TB/mydbs/ directory and executed this command:

chown -R _mysql:wheel data

6. Started the MySQL server. Again, you can do this with the System Preferences MySQL pane or you can do it like this:

mysqld_safe &

…borne back ceaselessly into the past

February 7th, 2009

Brains Are Doing It for Themselves

May 12th, 2008

This is an interesting article about Google, about it’s a great place to work, so why are so many people leaving? To paraphrase the Eurythmics and Aretha, brains are doing it for themselves. I was just thinking the other day that there must be a huge brain drain happening at Microsoft. The days of becoming a millionaire from stock options are over. Microsoft is not doing anything exciting or interesting. The original smart people have all already cashed out. Microsoft has a terrible reputation among the cognoscenti. Why would anyone want to work there? They’ve always hired people mostly straight out of college with no experience, at low wages, who join for the cachet and the stock options. But there is no cachet or stock options anymore. They must be getting the Computer Science dregs these days.

Google is another matter of course. They may be slightly on the downside of the glory days, but they are still a happening company. However, the internet, and Google for that matter, are bringing about the age of the individual entrepreneur. Being one myself, I can say that all of the stresses and sacrifices of being on one’s own and trying to start a business from scratch, are made up for by not having to put up with jerks and fools. I lament the many years I spent taking orders from idiots and making other people rich.

These guys who are leaving Google are leaving with vastly more money than I have ever had, access to venture capital, youth, and considerably more technical chops. Of course they’re leaving! I’m very happy being out here on my own, but I only did it because I had no other choice, and after two years of no income, I make a middle-class living. The ex-Googlers have options I’ve never dreamed of.

As the future unfolds, this is going to be a problem for every company that succeeds and becomes huge as a result. They will lose all their brains, the only capital asset that matters anymore, become stupid, and die. Microsoft is now in a death spiral, albeit a very slow one. Google is not there yet, but the end is inevitable. Not that Google will disappear. They will become a utility. Everyone who has played Monopoly knows what the utilities are worth. Microsoft, on the other hand, will just go under.

Apple is somewhat of an anomaly. It is really an example of an individual entrepreneur. It is Steve Jobs’ baby. You can still get rich on options there, and it is exciting, and has plenty of cachet, but without Steve Jobs Apple is dead meat. Apple stock is my entire retirement plan, and so far it is working out nicely. As long as Steve Jobs is alive, Apple will continue to take market share from Microsoft until it is all gone. They will also become the dominant player in music, TV, and movies. At that point, they may become a utility, but I will have already retired.

Actually Macs are Cheaper than PCs

April 28th, 2008

It is pretty generally accepted that, no matter how superior they may be, Macintosh computers are significantly more expensive than Windows PCs. Just out of curiosity, I decided to do a little comparison shopping. Apple just upgraded the iMac today, so I compared the price of the entry-level iMac with a comparable computer from DELL. Here are the specs:

Dell XPS One

  • 20 inch widescreen display with Intel® Core™2 Duo 2.2GHz
  • Adobe Elements Studio for XPS™ One
  • XPS One® Wireless Keyboard
  • XPS One® Wireless Mouse
  • 1Yr In-Home Service, Parts Labor, 24×7 Phone Support
  • Included 3 GB DataSafe Online Backup for 1Yr
  • Genuine Windows Vista® Home Premium
  • Norton Internet Security™ 2007 Edition 15-months
  • Microsoft Works 8.5 – Does not include Microsoft Word
  • 2GB Dual Channel DDR2 SDRAM at 667MHz – 2 DIMMs
  • 250GB Serial ATA 3Gb/s Hard Drive (7200RPM) w/DataBurst Cache™
  • 8-in-1 Media Reader Included
  • Internal PCI 802.11 a/b/g/n wireless network card included
  • 8X Slot load CD/DVD burner (DVD+/-RW)
  • Integrated Audio – 2.0 Speakers
  • Hybrid Analog/Digital TV Tuner with Remote Control
  • Internal Bluetooth 2.0 Included
  • Apple iMac

  • 2.4GHz Intel Core 2 Duo
  • 1GB 800MHz DDR2 SDRAM – 1x1GB
  • 250GB Serial ATA Drive
  • Apple Mighty Mouse
  • Apple Keyboard (English) + User’s Guide
  • Accessory kit
  • Integrated Speakers
  • SuperDrive 8x (DVD±R DL/DVD±RW/CD-RW)
  • ATI Radeon HD 2400 XT with 128MB memory
  • 20-inch glossy widescreen LCD
  • AirPort Extreme
  • Bluetooth 2.1 + EDR
  • remote control
  • iLife ’08 suite
  • Front Row
  • Photo Booth
  • 1 year .mac membership
  • They are not exactly the same of course. The Dell has a wireless keyboard and mouse. The iMac doesn’t. The iMac has a built-in iSight video camera. The Dell doesn’t. The Dell has 2GB of ram, the iMac only 1GB, but then Vista needs that much more ram than OS X to perform acceptably. The Dell CPU is slightly slower than the iMac. All in all, they are pretty close.

    The price tag on the Dell is $1,299. The iMac is $1,269, $30 cheaper than the Dell. This is not taking into account any differences in longevity, productivity, or resale value, all of which favor the Mac.

    Now it’s true that Dell has cheaper computers than the XPS One, but they are not at all comparable to the iMac. Apple just doesn’t sell low end products. What is not true is that you can buy a PC comparable to a Mac for a lot less, or any less, money.

    Cocoa Sheets How To

    April 9th, 2008

    Sheets, of course, being those windows that drop down from the top of, and are attached to, another window. It’s pretty simple, but I had a hard time finding any documentation or Google info about it.  So here is what I finally found/figured out:

    1. First create the windows or panels in Interface Builder that will be the sheet and the window/panel that the sheet is attached to. If your sheet is a panel, set the style to “Document Modal”.

    2. Then do this in obj-c:

    [NSApp beginSheet:mySheet modalForWindow:myPanel
         modalDelegate:self didEndSelector:NULL contextInfo:nil];
    [NSApp endSheet:mySheet];
    [mySheet orderOut:self];
    [mySheet performClose:self];

    I’m not sure if that last performClose statement is needed, but it can’t hurt.