OSX Audio Device - Select from CLI
Loren (mcint) October 27, 2022 [Terminal] #cli #macOSI can now switch audio device from the command line.
I installed switchaudio-osx
via homebrew, and
defined this osx-audio
convenience function, to show and switch outputs.
Basic usage looks like:
Brifely summarize more extensive use of the installed tool:
SwitchAudioSource [-c|-a] [-f [human|cli|json]]
Read as -c
current device, or -a
all devices.
And formats human
default minimal, cli
a compact csv, and json
a readable and labeled format.