Locking your screen when you leave is good security practice. But what if you want your Mac to do more than just lock?
Maybe you want to pause Music when you leave. Or turn off your desk lights. Or only lock when you're at work but not at home?
ProximityLock now integrates with macOS Shortcuts. Instead of being limited to screen locking, you can trigger any automation you want.
Shortcuts?
macOS Shortcuts is Apple's automation framework. It lets you chain actions together: check your location, call APIs, control HomeKit devices, run scripts, send notifications or interact with other apps on your Mac.
ProximityLock now has a "Run Shortcut" option alongside "Lock Screen" and "Start Screensaver". When your device goes out of range, it executes your shortcut instead of immediately locking the screen.
Real Examples
Location-Aware Locking:
A.k.a. Geofencing (sounds a bit scary?). But a shortcut can check how far or close you are from a specific location, like home, work, etc. Example shortcut here.
Smart Home Integration:
When you walk away, turn off your desk lamp via HomeKit. Or set your Hue lights to "away" mode.
Music and Media:
Pause YouTube or Music when you leave your desk.
Keyboard Lockout:
If you have a cat, you know the problem. You leave your desk, the cat immediately lies down on that warm spot (your Mac), and suddenly your Slack has sent "jjggdsjgjjjkkkkkk" to someone, an app has been closed, or worse, something was deleted. A shortcut can call BetterTouchTool to disable keyboard and mouse.
My cat didn't really like that I put my Mac on a stand:
API Webhooks:
Call a webhook when you leave. Log your presence. Trigger a serverless function. Whatever your workflow needs.
How to Set It Up
Create a shortcut in the macOS Shortcuts app. Name it something like "Mac Locked". Add whatever actions you want.
In ProximityLock settings, select "Run Shortcut" as your lock method. Enter your shortcut name and that's it.
When your Bluetooth device goes out of range, ProximityLock executes your shortcut. You can still lock the screen from within your shortcut if you want by adding Lock Screen or Start Screen Saver action.
Why?
It is all based on your feedback which is really honestly appreciated. Shortcuts integration was easy to develop and gives you much more control. ProximityLock still doesn't process any information like your location or need extra permissions.
Limitations
There are a few of them. Shortcuts run in the foreground briefly, so they're not completely invisible if it really matters. Complex shortcuts can take time to execute. If your shortcut fails, ProximityLock won't know it just fires and forgets so please test things out.
The shortcut runs on every trigger, even false out of range events, but ProximityLock is doing its best to avoid it. But still you need to be aware of this.
Remember: if you still want to lock the screen, add the Lock Screen action at the end of your shortcut.
The Bottom Line
It's about giving you control over what happens when you walk away from your Mac. Standard locking or screensaver when you need it. Custom workflows when you want more.