The Apotheosis Mac OS

February 5, 2017 at 4:49 PM by Dr. Drang

Whenever Apple announces downward trending sales figures for the iPad—which is to say, every quarter for the past few years—people go on the internet and try to explain why. The prevailing explanation among Apple enthusiasts is that the iPad is so good it just doesn’t have to be replaced very often. That led to a sales bubble in the early years and a decline ever since.

Operating System. Mac OS X 10.6+ Processor. Dual-core 2 GHz CPU. 300 MB free HD space. Nvidia GeForce 310 or equivalent graphics card. You Might Also Like: The Apotheosis Project €1.99 Subject 13 €9.99 Starship Quasar €3.99 Fanbots Free. How to Install Apotheosis Heroes for Windows PC or MAC: Apotheosis Heroes is an Android Role Playing app that is developed by So Fun So Hard and published on Google play store on NA. It has already got around 50000 so far with an average rating of 4.0 out of 5 in play store. Gros seems to have discontinued this larger version of Clovis and Clotilde later that year, when that composition was replaced by an alternative showing the apotheosis of Saint Genevieve. This unity under Clovis was transient, though: with four sons surviving him, the single state disunited into the separate kingdoms of Rheims (with Limoges. Apotheosis in music refers to the appearance of a theme in grand or exalted form. It represents the musical equivalent of the apotheosis genre in visual art, especially where the theme is connected in some way with historical persons or dramatic characters.

While there’s certainly some truth to that, I don’t think it tells the full story. All it does is lead to another question: Why are people satisfied with four-year-old iPads? For my money, David Sparks has given the best answer to that question.

In my mind, the issue is that users are not pushing the iPad harder to do more work for them, which would naturally end up in users wanting to buy newer, faster, and better iPads. Put simply, I think the issue is software.

At last year’s iPad Pro event Apple made a big deal about how the iPad is powerful enough to replace a PC laptop. I believe for a lot of people that could be true. But it’s not quite there yet because of the software limitations.

If Apple wants to see an increase in iPad sales, I think the answer is making them more useful and getting the word out. Apple should get serious about adding features to iOS that allows users to be more productive in getting their work done.

In other word—words that David wouldn’t be so crude as to use—it’s the software, stupid.

I have a 9.7″ iPad Pro. It’s a nice machine, and I’ve been taking it on business trips in lieu of my old MacBook Air. It’s perfectly fine for many things, but when I really need to get work done I bring the Air. It certainly isn’t because the Air’s hardware is more powerful. Here’s what I get running Geekbench 4 CPU tests (Mac, iPad) on the two devices:

DeviceSingle-coreMulti-core
2010 Macbook Air13552291
9.7″ iPad Pro29074737

Undoubtedly, a big reason I’m more productive on the Air is familiarity. As I use the iPad more, I’ll learn how to use it more efficiently. But David’s point still holds: productivity tools on the iPad just aren’t up to the Mac standard. Editorial is no BBEdit. And no combination of Workflow and x-callback-urls can compare with shell scripting, AppleScript, Keyboard Maestro, Hazel, et al.

What’s surprising to me is how slow iPad software has advanced in the seven years since its introduction. I’ve always thought of the iPad as the apotheosis of Steve Jobs’s conception of what a computer should be, what the Mac would have been in 1984 if the hardware were available. But think of what the Mac could do when it was seven years old:

  • You could write real Macintosh programs on it, both with third-party development software like THINK (née Lightspeed) C and Pascal and Apple’s Macintosh Programmer’s Workshop. You may not care about writing native apps, but the ability to do so brings with it a lot of other abilities you do care about, like the bringing together of documents from multiple sources.
  • You had a mature multi-tasking environment1 in the MultiFinder that worked with essentially every application that ran on the Mac.
  • You (and all your applications) had access to a real hierarchical file system.
  • You had what many people still consider the best personal software development kit in HyperCard.

And these were not new in 1991, they’d been around since 1987 or so.

In contrast, the iPad has Split View, which still hasn’t been adopted by some apps; iCloud Drive, which many people are afraid of because of iCloud’s history of unreliability; and Swift Playgrounds, which may be very nice for learning to program but isn’t being used for real apps or personal productivity.

The biggest problem for the iPad is Apple’s unwillingness to let it become its own thing. Development of iOS is driven by the iPhone, which probably shouldn’t have the tools of a regular computer. But the iPad needs at least some of those tools if it’s to fulfill Apple’s promise to be a laptop replacement. Being yoked to the iPhone is holding it back.

I have no interest in Apple’s financial condition per se. I care about it only to the extent that it influences Apple to provide me with good computing devices. I’d love to have my iPad oust my MacBook Air as my primary home computer. But it won’t until Apple gives it (and me) the tools to allow it take over.

  1. It was, unfortunately, not pre-emptive multitasking, which the Mac didn’t get until OS X. ↩

One thing that I’ve been playing with off and on for some time is a small efficient little solution for handling basic Bluetooth proximity detection, specifically for being able to perform certain actions when a cell phone or other Bluetooth device is in range of my Powerbook.

As an IT Consultant, I am frequently working in various locations at different clients’ sites, and it’s nice to have my Powerbook secure itself when I’m away from the machine. In addition, my other objectives are to keep the OS X Address Book application connected and to iSync my phone whenever it moves back within proximity of my machine.

Ideally, I would want to activate the OS X screen saver and enable the password protection when I move away from my computer (out of Bluetooth range), but otherwise I’d prefer to keep the screen saver password off for normal use, as it gets quite annoying when I’m working near the computer to have to continually re-enter my password after I’ve diverted my attention elsewhere for a few minutes (which happens frequently, as often the Powerbook sits to one side of other systems that I’m working with, rather than being in constant use).

Presently, the only software solution that will actually handle this with any kind of transparency from a security point of view is a tool called Home Zone that has been only recently released in beta form. While Home Zone looks like an excellent package to keep an eye on, it’s fairly new and may also be a bit more complex than the requirements of a basic Bluetooth proximity detection system. One neat feature, however, is that it also adds Wi-Fi detection to the mix. Home Zone also includes pre-defined actions to do things like Enabling and Disabling the screen saver password, a task that is otherwise more difficult to accomplish than one might expect.

Unfortunately, as of Beta 7, I had little success getting it to reliably detect the presence of a Bluetooth device even in the simplest configuration, and it became frustrating to have my screensaver kick in on me while I was working on the computer only because Home Zone had lost track of the Bluetooth device.

Another excellent tool that will handle proximity detection as part of its much more robust suite of features is Salling Clicker. This is an absolutely outstanding application, but again one that goes well beyond basic proximity detection. Further, since Salling Clicker is really just AppleScript-based in it’s operations, the basic solution and scripts that I describe below can easily be adapted into that as well (in fact, even though I’m a licensed user and big fan of Salling Clicker, the only reason I’m not using it for this purpose today is that proximity detection is not yet supported with the Nokia E62 that I use).

The tool I ultimately chose for the purpose of the detection itself is a little free app appropriately called Proximity. This is a thin little program that does one thing, but does it well — that is to sit in the background and scan for a given Bluetooth device at regular intervals. When it detects a change in the device’s availability, it simply calls one of two Applescripts: One for the device leaving range, and another for when the device enters range.

So, armed with that I set out to create two Applescripts that would perform the following tasks:

When the Bluetooth Device enters range:

  • Deactivate the Screen Saver Password.
  • Deactivate the Screen Saver.
  • Reconnect the phone to the OS X Address Book
  • Sync the phone using iSync

When the Bluetooth Device leaves range:

  • Activate the Screen Saver Password.
  • Activate the Screen Saver.

Activating the screen saver and performing an iSync are both tasks that are trivial to perform via Applescript. Reconnecting the Address Book and enabling and disabling the screen saver password protection is considerably more complicated, however, as I quickly discovered.

I should point out that most of what I am documenting here has been gleaned from various corners of the web, and therefore most of the ideas are not specifically my own. However, I decided to try and document some of this in one place in order to hopefully save others the several hours of searching that it took me to put it all together.

Activating and Deactivating the Screen Saver

Activating and Deactivating the screen saver itself is trivial to do through Applescript simply through the use of the following two Applescript commands:

Activating the Screen Saver:

Deactivating the Screen Saver:

Performing an iSync

Likewise, once iSync itself has been properly configured for your phone, performing an iSync is not much more complicated. A basic sync is performed with the following command:

However, for my own purposes, I chose to expand upon this. Specifically, I decided there was no point in having iSync automatically sync more often than every 15 minutes or so. This prevents it from kicking in every time I happen to wander away from the computer and back. The following script will only tell iSync to synchronize if a sync has not occurred in the last 900 seconds (15 minutes):

The Apotheosis Of Pennsylvania

Further, since the iSync window will otherwise tend to come up and get in the way when this happens, I prefer to keep it hidden with the following additional command:

This will have the effect of running iSync if the phone has not been synced in the last 15 minutes, and immediately hiding the iSync window from view. The iSync will continue to run in the background until it completes.

Reconnecting to the Address Book

Although Bluetooth support in the OS X Address Book is a very cool feature, the reality is that it has been poorly implemented up to this point in terms of it’s ability to stay connected to a Bluetooth phone, or even in terms of making this process scriptable via Applescript.

Fortunately, this was discussed some time ago in the Salling Clicker forums and incorporated into the proximity scripts that are included with Salling Clicker. The solution, it would seem, is to toggle an internal Address Book preference to force it look for its associated Bluetooth device the next time it starts up, and then just shut down the Address Book app and restart it. This is accomplished with the following snippet of code, which is a simplification of code pulled from the “Keep Address Book Connected” script included with Salling Clicker

Placed within the script that executes when entering proximity, this will toggle the option to find a Bluetooth device ON in the Address Book preferences, and then shut down and restart the Address Book app. It’s messy, but it does work.

The Apotheosis Mac OS

(I’m sure I’m not alone in hoping that Apple makes this function accessible through Applescript in Leopard).

The Final Challenge: Enabling and Disabling the Screen Saver Password

The final hurdle in this process was programmatically changing the password protection on the OS X screen saver. While this is handled very elegantly by the Home Zone application that I mentioned at the beginning of this article, I wanted to find a way to do it programmatically through Applescript myself for various reasons. It turns out this process was slightly more complex than I had initially suspected.

The Apotheosis Of Lincoln

Firstly, the preference that determines whether the OS X screen saver asks for a password is stored within each user’s local preferences, specifically in the com.apple.screensaver domain. The preference file itself is a little tricky, as it is named based on a host ID. Fortunately, it can be accessed using the built-in “defaults” command-line tool. The specific key is “askForPassword” and contains an integer value of zero or one to determine whether the screensaver prompts for a password or not.

The following command, executed in terminal or from a “do shell script” within Applescript, will set this value to enable password protection on the screen saver:

This is well-documented in several places on the Internet, although there a couple of important things that should be noted.

Firstly, it is necessary to specify the “-int” parameter. Without it, the “defaults” command will write the value as a string value, which will be treated as an “OFF” setting regardless of the content. More specifically, anything in that key other than an integer 1 will disable the screen saver password.

More importantly, however, this setting does not take effect immediately. Either the System Preferences application must be opened and other changes made, or the user must log out and back in. This is because the password requirement is only read by the loginwindow process.

By default, changes in the “System Preferences” app in OS X will send a notification to the loginwindow process to re-read these settings. However, to change the setting programmatically and have it take effect immediately, it’s necessary to find an alternative way to refresh the loginwindow process.

After much digging, the solution was found in a thread on the macosxhints forum, in the last post by Guillaime O. Specifically, Guilaime provides a snippet of C code that can be quickly and easily compiled into an executable to perform this specific function.

This code can simply be compiled with the built-in C compiler on OS X (if you have the Development Tools installed), and then simply put somewhere in the path. Then, immediately after running the defaults command to set the screen saver password state, simply call this application to refresh the loginwindow process and re-read the “askForPassword” setting.

For my own purposes, I just went with the suggested name of “notif” for the executable, but it can of course be named anything you like.

The Final Result

So, after all is said and done, the final result is the following two scripts:

Entering Proximity.scpt

Leaving Proximity.scpt

Other Possible Tricks

One other approach I had tried was to make use of the “CGSession” command to do a lock by returning to the actual login screen (effectively a fast-user-switching feature that presents the login screen without logging the user out). While this was a very neat solution, it lacked the intuitive “unlock” feature, since once returning to the login screen, there was really no way to get back in without a password (at least not a simple method that I have yet discovered without embedding my password somewhere in the file).

However, for those interested, the following Applescript entry will accomplish this task:

This works reasonably well, and the entering proximity script will even run in the background, so the only disadvantage is that you are forced to log in manually when you return to the computer, and there is a small delay in this process.

Once thing I was able to do with this, however, was to combine it with another tool, the excellent SleepWatcher daemon, to allow me to run shell scripts when the computer wakes or sleeps. I simply instruct SleepWatcher to run a script including the above command with a slight delay to allow it to complete, and then whenever the computer goes to sleep, my session is returned to the log in screen.

While the Bluetooth proximity detection feature will also address this (if the computer is awakened without the necessary Bluetooth device nearby), this option is slightly more secure, and allows for the ability for somebody else to log onto the computer if necessary (a screen saver password would restrict access to the currently logged in user only).

References & Acknowledgements

Again, most of what is discussed in here has been gleaned and put together from information in various places on the Internet. Specifically, the following should be acknowledged:

Proximity 1.0A very simple and effective free Bluetooth Proximity detection tool for Mac OS X
Home Zone beta 7A very slick up-and-coming solution by Jonas Witt to set parameters based on “Zones” which are in turn based upon Wi-Fi and Bluetooth proximity.
Salling Clicker 3.0.1Jonas Salling’s absolutely outstanding Bluetooth remote control and proximity detection app, and the source for the Address Book reconnect script included above.
SleepWatcher 2.0.4A neat little daemon by Bernhard Baehr to monitor and execute shell scripts based on sleep and wake events.
Mac OS X HintsMost of the solutions and script snippets regarding the screen saver password protection came from the Mac OS X Hints forum. Specifically, the simple but indispensable C code for the “notif” application was contributed to these forums in a post by Guillame O.