Skip to content

Instantly share code, notes, and snippets.

View ieatfood's full-sized avatar
🐈‍⬛
Is a cat

Kuba Holuj ieatfood

🐈‍⬛
Is a cat
View GitHub Profile
@ieatfood
ieatfood / Connect Airpods.applescript
Last active May 16, 2024 09:52 — forked from jaredmoody/Connect Airpods.applescript
An Applescript to connect bluetooth devices, such as Airpods. Nice when paired with an alfred trigger.
# Taken from https://www.reddit.com/r/MacOS/comments/i4czgu/big_sur_airpods_script/gck3gz3/
# by https://github.com/smithumble
use framework "IOBluetooth"
use scripting additions
set AirPodsName to "AirPods"
on getFirstMatchingDevice(deviceName)
repeat with device in (current application's IOBluetoothDevice's pairedDevices() as list)