I use a shell script to back up this site (and a variant of the same script to back up the Many Tricks site). I’ve been using these scripts for over a decade (wow), and though they’ve evolved, they’re still fundamentally the same. (I did switch from cron to launchd for launching them, however.)
While the script typically runs very nicely, I recently noticed that my last backup was from a few weeks ago—uh oh. It didn’t take long to figure out what had gone wrong: My ISP changed the hostname of the machine my site runs on, and my script uses ssh, scp and rsync, which connect via the hostname. Unfortunately, the failure mode is silence, because the script runs via a scheduled task. The only way I knew it failed was when I went to check the backup folder. Obviously, something more automatic than that would be desirable.
After much web searching, I couldn’t find anything that seeemed like it’d do what I want: An email (and onscreen alert) if my backup failed. I found lots of Unix solutions to send mail using sendmail, but I didn’t really want to enable that on my Mac. So I futzed around and built a simple checker that will mail me when it can’t reach my web host.
Today’s tip is simple, yet for me, critical—it’s one of the first things I do when I set up a new Mac or user on an existing Mac, as it solves a vexing issue: Small fonts that can’t be modified within an app’s preferences. As my eyes get older, these small fonts get more and more annoying.
Thankfully, there’s a fix in the Accessibility section of System Preferences, specifically on the Zoom tab: Easily zoom the screen via keyboard or gesture shortcut. Here’s the setup screen:
You can choose to use keyboard shortcuts to zoom (top section of the full screenshot), or (my preference) a scroll gesture with a modifier key. There are also some useful options in the “Zoom style” section.
I tweeted this recently…
Things I did not know (or perhaps remember): Terminal lets you set the opacity and blur of inactive windows. (Profiles > Text > Background)
…but because I often forget about those things—the ephemeral nature of tweets being what it is—I figured I should post it here, too.
I have no idea when the feature appeared, but I only discovered it on February 27th, when I tweeted about it. You’ll find the window at right in Terminal’s preferences, on the Profiles tab—look in the Text section for a selected window, then click the color tile under Background. Check the box to set opacity and blur for inactive windows, and you’re done.
As I use a dark background in Terminal, I like this feature a lot. I’ve now got it set up to go transparent and fuzzy when inactive—this makes it basically vanish, so the dark background no longer grabs my eye.
At some point, I’ll dig through my virtual machines and figure out when this was added…who knows, maybe it’s been there for forever. In any event, I’m glad I stumbled across it the other day.
My home workspace is a 27″ Retina 5K iMac (2560×1440) paired with a vertical 4K display (scaled to view 1440×2560). While I love this setup in general, there’s one time it’s annoying: When I need to move the cursor between displays, and it’s located far away from its destination.
There are many ways to solve this problem, including our own Keymo, which I still use when I want to teleport a drag across displays. But what I really wanted was a fast way to move the cursor to the other display when I switched to a window on the other display—because generally, if I’ve activated the window, I’m probably going to use the mouse in that window at some point.
Using Keyboard Maestro, it’s possible to create a macro to make this happen automatically:
This macro will activate every time you switch applications, and then move the mouse to the center of that newly-frontmost window and highlight its location with a quick circle. Having tested this, however, I can say it’s a non-ideal solution: Most of the time when I switch an app, I do not want the cursor to move. I found it more annoying—much more annoying—than useful.
As useless as the above macro is, with one minor change it quickly became one of my most-used macros…
A tweet I sent last night triggered my memory of this very-useful tip that I’ve gotten worse about remembering to implement over the years. First, the tweet…
The issue, of course, is the macOS ships with ⌘O (Open) and ⌘P (Print) as pre-assigned keyboard shortcuts in Finder. Select a bunch of files to open, reach for the O and miss by just a touch, and you’ve started a dozen print jobs. Whoops!
Years ago on macosxhints.com, there was one of those “duh!” tips with an easy solution to this (and other similar) issues: Reassign the stock keyboard shortcuts. Here’s a “fixed” Print shortcut in Finder, for example:
And with that simple change, no more accidental print jobs.
Changing the shortcuts is easy; start by opening System Preferences > Keyboard, then going to the Shortcuts tab. Scroll to the bottom of the left-hand pane, select App Shortcuts, then click the plus sign. You can then select an app—or all apps—from the first pop-up menu, enter the menu item to change/assign in the first input box, and type the shortcut to use in the third:
You can do this for as many of the stock shortcuts as you wish…and obviously, you can add some that you feel Apple left out. Read on to see what I change in the Shortcuts section—not just for applications, but in all of the sections (Launchpad & Dock, Mission Control, etc.)
When I’m working in Excel, I spend a lot of time in the Paste Special dialog box—pasting formulas, pasting all but formats, pasting only formats, etc. You can call up the dialog with a keyboard shortcut (⌃⌘V), but it then looks like you’re stuck using the mouse, because there aren’t any keyboard shortcuts for the various actions. But really, there are…
(Note: This applies to the current version of Excel, i.e. the one in Office 365. Based on the comments, it apparently also works in Excel 2011 if you add the Command key.)
On Excel for Windows, one character in each option has an underline, indicating that option’s keyboard shortcut. The good news is that these same shortcuts work on the Mac, even though they’re not shown. (There is one apparent oversight: The O key should select Operation: None, but it doesn’t seem to work on the Mac.)
Here are all the shortcuts, graphically:
Press the highlighted key, and that action will be selected; press Return to execute the chosen command, and you can use the Paste Special dialog without ever touching the mouse. (Note that the Paste Link action executes immediately when chosen, so it’s a one-key operation.)
Because graphics are horrid for web searching, the text version of each shortcut, in alphabetical order, is shown below.
Thanks to the commenters for pointing out the much easier way to do this: Select an item in Finder, then press Command-Option-C. All done. Leaving the hint here as an example of a Rube Goldberg machine.
In two recent geeky tips, I showed how you can open a Terminal window in the directory of the selected Finder item, and how you can view Unix man pages in Preview. To finish the trifecta of geekiness, today’s tip lets you quickly place the Unix-style path to the selected Finder item on the clipboard. (It’s actually a simplified version of the ‘open this in Terminal’ tip.)
The AppleScript that accomplishes this is quite simple:
tell application "Finder"
set sel to the selection as text
set the clipboard to POSIX path of sel
If you run that in Script Editor, you’ll see that your clipboard contains the path to whatever you had selected in Finder. But running the AppleScript in ScriptEditor isn’t a great timesaver. Instead, put it into whatever tool you have that can run AppleScripts via hot key or menu bar entry or whatever.
In my case, I put it into a super-simple Keyboard Maestro macro. I’ve set it up to show in the Keyboard Maestro menu bar when Finder is active:
There are countless tools that can run AppleScripts in various ways, including our own Butler, LaunchBar if you save the script first, etc.
Today’s tip is just a re-implementation of a really old Mac OS X Hints AppleScript that lets you open a Terminal window with the working directory set to (i.e. cd‘d into) the selected Finder folder.
This makes it really easy to jump into Terminal to do something from Finder, without having to do any mousing and minimal typing. What’s new is that I’ve used Keyboard Maestro to turn the AppleScript into a macro that runs only in Finder, where it’s available via hot key or menu bar trigger.
Here’s the complete macro; download it now to look at and/or use as you wish. [Note: If you use iTerm2 instead of Terminal, you’ll want to download this version instead. My good friend James, who runs Out of Control, did so. He tells me it works great.]
The name of the macro may look a bit odd—the 03) controls the sort order in the Keyboard Maestro menu bar item, and does not display when the menu is activated:
Keyboard Maestro also helpfully displays the assigned keyboard shortcut in the menu bar item, in case I’ve forgotten it.
Late last year, just after its 14th birthday, Mac OS X Hints was officially put into a coma. The site exists online, but it’s no longer accepting hints, and exists in a static state.
While it’s great that this information is still online—as there are tons of still-useful tidbits there—it’s apparently not searchable. When you enter something in the search box and press Enter, nothing happens…well, not nothing: The page reloads with an empty search box. Without search, the huge database isn’t quite so useful.
The good news is that Google and Bing have indexed the static site, so you can use their search engines instead of the site’s search engine. Even better is that you can build complex queries that aren’t possible when searching directly on the site.
To search the hints site from Bing or Google, just include site:hints.macworld.com in the search string. A few quick examples:
While this isn’t quite as handy as searching directly on the Hints site, it works well. (To make it easier, I’ve created a Butler search engine entry that searches hints via Bing.)
Note: The following is my unofficial eulogy for Mac OS X Hints;
IDG has not announced any plans regarding the site, though I would hope they’ll leave it online, even if no new hints appear in the future. The site is now officially in read-only mode; there will be no new hints. So it’s officially comatose, at least.
On this, the occasion of its 14th birthday, we’re gathered here to mark the passing of Mac OS X Hints.
While it can be hard to tell exactly when a web site has died, the signs are fairly obvious. It’s been over 45 days since the last new hint appeared on the site. There is no way for new users to sign up for an account. There’s been one new comment posted in the last two days. A sidebar box proudly proclaims Latest Mountain Lion Hints. The site design, logo, and icons were last updated when I worked for Macworld, over four years ago. To paraphrase a Star Trek character, “it’s dead, Jim.”
To be fair, it’s a bit more Monty Python “I’m not dead!” than officially dead, but really, the site is a dead man walking. Now that I’m done with movie analogies, let me explain why the passing of Mac OS X Hints isn’t a bad thing. (Note that Mac OS X Hints’ passing is in no way a reflection of its management by Macworld. In fact, the opposite is true: I believe the site would have ceased to exist years ago without their involvement.)
The simple truth is that the need for OS X hints has tapered off to near zero over the last 14 years. And that’s a good thing.