Skip to content
abuschPublic

About

A simple TUI for controlling Sonos speakers

Topics

Resources

Stars

29 stars

Watchers

2 watching

Forks

Latest commit

 

History

189 Commits

Folders and files

Repository files navigation

Sinuous

crates.io dependency status CI

Sinuous is a terminal user interface for controlling the Sonos speakers on your local network.

screenshot

Features

  • See what each group of speakers is playing, and switch between them
  • Play, pause and skip tracks, and toggle shuffle, repeat and crossfade
  • Adjust the volume of a group, or of each of its speakers
  • Group and ungroup speakers
  • Play your Sonos favorites
  • Album art, drawn with the Kitty, iTerm2 or Sixel graphics protocols in terminals that support one of them, and with coloured blocks otherwise
  • Themes, and icons for terminals using a Nerd Font

Sinuous talks to the speakers directly, through their local websocket API (using sinuous-client), and finds them with SSDP: no Sonos account is needed, but the speakers need to be on the same network as your computer.

Installation

Download the binary for your platform from the releases page, or install it with Cargo:

cargo install sinuous

Usage

Run sinuous. It connects to the first speaker it finds on the network, and lets you control all the speakers of its household.

To connect to particular speakers, give them with --device, separated by commas. IPv4 addresses work even when the speakers can't be discovered, e.g. because they are on another network. Names pick the household to control when several are discovered:

sinuous --device 192.168.1.10
sinuous --device "Living Room"

Key bindings

Key Action
Space Play / pause
p / n Previous / next track
s / r / c Toggle shuffle / cycle repeat (all, one, off) / toggle crossfade
[ / ] Volume of the group down / up
v Volume of the group and of each of its speakers
g Switch to another group, from a panel showing what each group is playing
G Add speakers to or remove speakers from the group
f Play one of your Sonos favorites
, Settings
? Keyboard shortcuts
q Close what is open, or quit

Panels and popups show the keys to use in them at their bottom.

Configuration

Sinuous reads its settings from ~/.config/sinuous/config.toml (or $XDG_CONFIG_HOME/sinuous/config.toml, or %APPDATA%\sinuous\config.toml on Windows), if it exists. Use --config <path> to read another file instead. All settings are optional. The [ui] settings can also be changed while running by pressing ,, which saves them to the file:

[core]
# The speakers to connect to, as IPv4 addresses or names. Speakers are
# discovered via SSDP if not set. `--device` overrides this.
devices = ["192.168.1.10", "Living Room"]

[ui]
# Whether to show the album art of the current track.
album_art = true
# Whether to show icons instead of labels for actions, play modes and kinds of
# sources, and before the names of music services. Requires a Nerd Font
# (https://www.nerdfonts.com).
nerd_font = false
# The colours to use: "terminal" for the terminal's own, or one of the themes of
# opaline (https://github.com/hyperb1iss/opaline#-builtin-themes): ayu-dark,
# ayu-light, ayu-mirage, catppuccin-frappe, catppuccin-latte,
# catppuccin-macchiato, catppuccin-mocha, dracula, everforest-dark,
# everforest-light, flexoki-dark, flexoki-light, github-dark-dimmed,
# github-light, gruvbox-dark, gruvbox-light, kanagawa-dragon, kanagawa-lotus,
# kanagawa-wave, light-owl, monokai-pro, night-owl, nord, one-dark, one-light,
# palenight, rose-pine, rose-pine-dawn, rose-pine-moon, silkcircuit-dawn,
# silkcircuit-glow, silkcircuit-neon, silkcircuit-soft, silkcircuit-vibrant,
# solarized-dark, solarized-light, tokyo-night, tokyo-night-moon,
# tokyo-night-storm.
theme = "terminal"

Troubleshooting

To get debug logs, run RUST_LOG=sinuous=debug sinuous. The logs are written to sinuous.log in the temporary directory: $TMPDIR on macOS, /tmp on Linux, and %TEMP% on Windows.

Ideas

  • Seek forward and backward
  • Search for tracks, and manage the queue
  • Show more information about the current track

License

MIT

About

A simple TUI for controlling Sonos speakers

Topics

Resources

Stars

29 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages