switchaudio-osx
brew install switchaudio-osx
v1.2.2
MIT
Change macOS audio source from the command-line
1.4k
30-day installs · #1156
3.5k
90-day · #1272
9.3k
365-day · #1478
1.4k
★ GitHub stars · updated 2y ago
Links
- https://github.com/deweller/switchaudio-osx/
- GitHub: deweller/switchaudio-osx
- Brew formula source: Formula/s/switchaudio-osx.rb
Raw metadata
{
"aliases": [],
"alternatives": [],
"build_dependencies": [],
"categories": [],
"caveats": null,
"conflicts_with": [],
"dependencies": [],
"deprecated": 0,
"deprecation_reason": null,
"desc": "Change macOS audio source from the command-line",
"disable_reason": null,
"disabled": 0,
"enrichment_fetched_at": "2026-06-20T23:41:21+00:00",
"first_seen": "2026-06-20T23:34:18+00:00",
"full_name": "switchaudio-osx",
"github_default_branch": "master",
"github_last_commit_at": "2024-07-07T17:06:56Z",
"github_readme_excerpt": "switchaudio-osx\n===============\n\nA command-line utility to switch the audio source on Mac OS X.\n\nDescription\n-----------\n\nThis utility switches the audio source for Mac OS X.\n\nYou specify the name of the audio source, such as Built-in Digital Output, and the utility switches the source immediately without any GUI interaction.\n\nThis is a command-line utility only and has no graphical user interface. Tested on OS 10.7 - 11.2.\n\nInstalling from homebrew\n------------------------\n```\nbrew install switchaudio-osx\n```\n\nUsage\n-----\n\nSwitchAudioSource [-a] [-c] [-f format] [-t type] [-n] -s device\\_name | -i device\\_id | -u device\\_uid \n\n - **-a** : shows all devices\n - **-c** : shows current device\n - **-f** _format_ : output format (cli/human/json). Defaults to human.\n - **-t** _type_ : device type (input/output/system). Defaults to output.\n - **-m** _mute_mode_ : sets the mute status (mute/unmute/toggle).\n - **-n** : cycles the audio device to the next one\n - **-i** _device_id_ : sets the audio device to the given device by id\n - **-u** _device_uid_ : sets the audio device to the given device by uid or a substring of the uid\n - **-s** _device_name_ : sets the audio device to the given device by name\n\n### Muting\n\nThe `-m` flag can be used to mute input or output devices.\n\nDefine the device via `-t`.\n\nExample for toggling the mute state for the currently selected input, e.g. microphone:\n\n```shell\nSwitchAudioSource -m toggle -t input\n```\n\nThis is useful on a hotkey, e.g. to mute your Teams or Zoom input.\n\nThanks\n-------\n\nThanks to Christian Zuckschwerdt for migrating this to github and adding the next option.\n\nLicense\n-------\n\nMIT License, see license.txt \n\nCopyright (c) 2008-2021 Devon Weller \u003cwellerco@gmail.com\u003e \nCopyright (c) 2011 Christian Zuckschwerdt \u003czany@triq.net\u003e\n",
"github_repo": "deweller/switchaudio-osx",
"github_stars": 1422,
"github_topics": [],
"homepage": "https://github.com/deweller/switchaudio-osx/",
"homepage_og_description": null,
"homepage_og_image": null,
"homepage_title": null,
"installs_30d": 1365,
"installs_365d": 9300,
"installs_90d": 3468,
"keg_only": 0,
"keg_only_reason": null,
"last_seen": "2026-06-20T23:34:18+00:00",
"license": "MIT",
"llm_generated_at": null,
"llm_model": null,
"name": "switchaudio-osx",
"oldnames": [],
"one_liner": null,
"optional_dependencies": [],
"rank_30d": 1156,
"rank_365d": 1478,
"rank_90d": 1272,
"raw_hash": "734efd8cd5735d59",
"recommended_dependencies": [],
"revision": 0,
"ruby_source_path": "Formula/s/switchaudio-osx.rb",
"tap": "homebrew/core",
"test_dependencies": [],
"uses_from_macos": [],
"version_head": "HEAD",
"version_stable": "1.2.2",
"versioned_formulae": [],
"why_use_this": null
}