Set Default printer based on physical location (preferably) vs Wifi MAC address

At the end I found that using IP address did not work for me - due to inconsistencies between different sites in the organization I work for.

I changed that script to work based on location. The script runs 10 seconds after computer wakes up, at login or on connection to a specific WiFi.

You need to download and install Location helper from Mac App Store (https://apps.apple.com/us/app/location-helper/id488536386?mt=12) and also Split Text KBM plug-in (Split Text - Plugin Action).

To make the script work, change WiFi name to the one you use. Run lpstat -p in terminal and change all the printer names I used to the printer names you use. Run Location helper in each one of the locations you use your laptop and replace my coordinates with yours (You can run this part of the script separately to get the truncated numbers:

DEFAULT PRINTER (Location Helper) .kmmacros (15.5 KB)