#!/usr/bin/env bash
set -x
rfkill unblock bluetooth
echo $"stdin for btmgmt" | btmgmt -i hci0 public-addr $(hciconfig hci0 | grep -o $"[[:xdigit:]:]\\{11,17\\}")
# btmgmt requires stdin, so we feed it some garbage...