iPhone Screenshots
Description
It is simple:
You unlock the Mac - it runs your selected Shortcuts
You lock your Mac - it runs another Shortcuts
Add anything you want to a Shortcuts automation and select it from the app's dropdown menu.
For example, I've added light control to my shortcuts - now my monitor backlight and desktop lamp turn on and off automatically.