← 返回
开发者工具

macos-audio

Manage macOS audio output and Bluetooth devices via the macos-audio CLI. Use when scanning paired devices, connecting or disconnecting Bluetooth, switching a...
通过 macos-audio CLI 管理 macOS 音频输出和蓝牙设备,支持扫描配对设备、连接/断开蓝牙及切换输出。
vossenwout
开发者工具 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 1
Stars
📥 606
下载
💾 18
安装
1
版本
#latest

概述

macos-audio

Control Bluetooth devices, audio output routing, and volume on macOS through

the macos-audio CLI.

Installation

Brew dependencies

brew install switchaudio-osx   # required for output switching
brew install blueutil           # required for Bluetooth control

Install the CLI

brew install vossenwout/tap/macos-audio-cli

Commands

Scan & connect

macos-audio scan                # clean sections: Bluetooth, Local, AirPlay
macos-audio connect bt <name|mac>
macos-audio connect airplay
macos-audio connect local <name>
macos-audio disconnect <target> # disconnect bluetooth and switch to local output

Volume

macos-audio volume set <0-100>  # set system output volume
macos-audio volume get          # print output volume, input volume, mute state

Playback

macos-audio play <file>                    # play a local audio file
macos-audio play <file> --background       # start playback and return immediately

Status

macos-audio status                         # show output, volume, mute state
macos-audio status --json                  # same but machine-readable JSON
macos-audio status --device <name|mac>     # include bluetooth status for a specific device

Exit codes

CodeMeaning
---------------
0Success
1Runtime error
2Bad arguments
3Target resolution error
4Missing tool dependency (blueutil or SwitchAudioSource not installed)

Workflow guidance

  • Always run macos-audio status first to understand the current state before making changes.
  • If a command exits with code 4, the required brew dependency is missing — install it and retry.
  • connect airplay uses the generic AirPlay route; room names in scan are informational.
  • Bluetooth devices only appear in scan after manual pairing in macOS.

Limitations

  • Doesn't work over ssh
  • connect airplay is known to be buggy and airplay functionality is still experimental

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-19 12:20 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

content-creation

claw-radio

vossenwout
运营广播电台,学习成为AI电台主持人并使用claw radio CLI工具。
★ 0 📥 491
developer-tools

Github

steipete
使用 `gh` CLI 与 GitHub 交互,通过 `gh issue`、`gh pr`、`gh run` 和 `gh api` 管理议题、PR、CI 运行及高级查询。
★ 668 📥 323,975
developer-tools

Gog

steipete
Google Workspace 命令行工具,支持 Gmail、日历、云端硬盘、通讯录、表格和文档。
★ 921 📥 185,767