honk 0.3.0

Make your computer honk like an old-school car. Honk, honk!
honk-0.3.0 is not a library.

honk

Make your computer honk like an old-school car. Honk, honk!

honk is a toy with a job. Put it after a long build, a test run or a deploy, and your computer tells you how it went with a sound you can't miss: a cheerful honk when it worked, a sad, sagging one when it failed. You don't have to keep the terminal in view, or look at a screen at all.

Quick start

brew install mklab-se/tap/honk
honk                      # Honk, honk!
honk --style awooga       # a-WOO-ga
cargo build && honk       # tell me when it's done
                       ⣼⠉⠉⠉⠙⠛⠛⠒⠒⠒⠒⢲⡄
                       ⣸⣆⣀⣀⣀⣀⣀⡀ ⠐  ⣧⣠⡀
     ⣴⣶⣲⣶⣒⡒⠒⠒⣒⣒⠒⣒⣒⠶⣦⣄⣀⡀⠸⣇   ⠉⡩⠉⠉⠉⠉⠉⣿⣿⠧⣶⢦ ) )   HONK!
     ⢨⣿⠮⣽⣿⣿⣿⣍⣍⠩⠙⡉⠻⡙⡍⠉⠉⠩⠹⣿⣶⠶⠶⠛⠒⠚⣶⡶⣶⣶⣯⣿⣟⣳⣊⣀⣀⣀⣀ ⢠⣤⡀
      ⠈⢙⣛⡿⠿⠿⠿⢿⠲⣦⣠⣀⣹⣘⣌⣀⣆⡷⣧⡇   ⡴⠋           ⠉⡩⠛⡩⠚⣗⠢⡄
   ⢀⢠⠖⠋⠉⠁     ⢀⣤⡀     ⠐⡇ ⠈⠉⠁⢸⠓⠒⠒⠒⠒⠒⠒⠒⠒ ⠠⠤⠤⢴⠃⢸⣷⣶⣿⣿⣿ ⣀⣀
   ⢻⣧⣒⣀⣀⠒⠦⡀    ⢫       ⡇    ⢸ ⠠    ⠄⣀⣀⣀⣀⣀ ⢸⢶⣿⠿⣿⣿⣿⣿⣾⣿⠋⣷⠐ ⠤⣀
 ⢿⣶⣿⣿⡿⠿⣿⣷⡀⠈⢦   ⢸       ⡇    ⢸ ⢐ ⢀⣤⢞⣫⣥⣤⣶⣦⢄⡉⠚⠿⣿⢀⣼⣿⣿⣿⣻⣿⡤⠇⣠⣤⣤⣄⠑⡄
 ⢰⣿⡟⣡⣶⣶⣦⡙⣷⡀⠈⢧⡀  ⠣⢄⣀⣀⣀⣀⣠⠇    ⣸⣀⡀⣠⣿⣿⣿⠿⠛⠛⠛⠿⣿⣮⣗⣂⣸⣿⣿⣿⣿⣿⡝⠻ ⣸⣿⣿⡟⢷⣄
⣿⣿⣿⢰⣿⣿⣿⣿⣷⡸⡇ ⢸⡉⠉⠉⠉ ⠒⠒⠒⠒⠒⠒⠒⠦⠤⠤⠿⢤⣼⣿⣿⡟⣡⣶⣿⣿⣿⣶⣌⢻⣿⣿⣿⣿⣿⣿⣿⣿⣁⡀⢀⣇⣇⡼⠙⣆⢻⡆
⠉⠉⢉⢸⣿⣿⣮⢹⣿⡇⣷⣀⣛⣇⣀⣀⣀⡀     ⣤    ⣠⣾⣿⣿⡟⣰⣿⣿⣿⣿⣿⣿⣿⣆⢹⣿⣿⡿⣟⢻⡟⣹⣧⢏⣙⠻⣏⣷⣋⣹⠈⣿
  ⠸⢸⣯⣹⣭⣾⣿⡇⣿⡟⠿⠿⠿⠿⠿⠿⢿⣿⣿⣿⣶⣿⣶⣶⣦⣾⣿⣿⣿⣿⡇⣟⣿⣿⣿⣭⠻⣿⣿⣿⡄⣿⣿⣷⣦⣩⣿⡿⣿⣛⣻⣿⣿⡿⢥⣸ ⣿
   ⢃⢻⣧⣏⣹⡜⣸⡿       ⠈⠻⠿⣿⡿⠟⠉⠉⠁  ⠉⠉⠙⡇⢿⡏⢛⣷⡾⢋⣿⣿⣿⡇⣿⣿⡿⠿⠿⠿⢻⣿⣯⣨⠏⡏⠹⣤⠟⣸⡏
    ⠑⢬⣉⣩⡼⠟⠁                     ⢱⠸⣿⡏⢸⠛⡿⢿⡋⣹⢀⣿⠇     ⠙⢿⣿⡷⠿⠞⣋⡼⠏
                                 ⠳⡘⢿⣿⣄⣧⣤⠿⢁⣾⠟        ⠉⠙⠛⠋⠉
                                  ⠈⠲⢬⣉⣉⣡⡴⠟⠁

Hear it, don't watch it

Most "it's done" signals are visual: a pop-up, a badge, a red line in a terminal you have to be looking at. honk tells you through your ears instead.

  • Know the outcome without looking. Success and failure sound different: the happy honk bends up at the end, the sad one is longer and sags down. You hear whether it worked, not just that it finished.
  • Tell jobs apart by ear. Give each long job its own horn, and you know which one finished from across the room: honk --style truck -- ./deploy.sh, honk --style clown -- cargo test.
  • Step away from the screen. Make coffee, read on paper, rest your eyes, or work in another window. The honk comes to you.
  • Works with screen readers. honk never writes to stdout, the wrapped command's output passes through untouched, and any problem is one plain-text line on stderr. The car is decoration only: a screen reader would read its Braille dots out as dot patterns, so add -q (or alias honk='honk -q') to switch it off.

Five horns

Style Sounds like Try it
car (default) A classic dual-tone car horn, two notes a major third apart honk
bulb A squeezed rubber bulb horn on a vintage car honk --style bulb
awooga The Model T klaxon: "a-WOO-ga" honk --style awooga
truck A low, slowly beating air horn honk --style truck
clown A short, high, wobbly squeak honk --style clown

Every honk is synthesised on the fly: no audio files, nothing to download.

Notifier mode

honk knows how your command went. Success gets a happy honk that bends up at the end; failure gets a sad, longer honk that sags down.

# Honk when it's done, whatever happened
cargo build && honk

# Happy or sad, depending on the exit status
make test; honk --status $?

# Run the command for you, honk by outcome, and pass its exit code through,
# so && chains and CI keep working
honk -- cargo test

# Make a deploy impossible to miss
honk --times 5 --style truck -- ./deploy.sh

With honk -- cmd, the command's output is untouched and honk exits with the command's own code (127 if it could not be started).

Shape it

Flag What it does
--times N Number of honks, 1 to 10 (default 2)
--long Longer honks
--pitch X Pitch multiplier, 0.5 to 2.0
--volume X Volume, 0.0 to 1.0 (default 0.8)
--wav FILE Write the honk to a WAV file instead of playing it
-q, --quiet No car

The car only appears when stderr is a terminal, so pipes and logs stay clean, and the honk itself never writes to stdout.

Make it yours

Put your favourite honk in config.yaml and plain honk uses it. Flags still win.

style: awooga
volume: 0.5
times: 3
Platform Location
Linux ~/.config/honk/config.yaml
macOS ~/Library/Application Support/honk/config.yaml
Windows %APPDATA%\honk\config.yaml

Set HONK_CONFIG_DIR to use a different directory.

Works everywhere

  • Linux through the player your system already has (pw-play, paplay or aplay), so it works with PipeWire, PulseAudio and plain ALSA, with nothing extra to install.
  • macOS through CoreAudio.
  • Windows through WASAPI.

No speaker? No problem: on a headless server, in CI or over SSH, honk prints one warning and exits 0 (or with the wrapped command's code), so it never breaks a build. Set HONK_NO_AUDIO=1 to turn the sound off on purpose (honk still prints that one warning line).

Install

Method Command
Homebrew (macOS, Linux) brew install mklab-se/tap/honk
Cargo cargo install honk
cargo-binstall (prebuilt, no compiling) cargo binstall honk
Prebuilt binaries Linux, macOS (Intel and Apple Silicon) and Windows on the Releases page

Every release ships a CycloneDX SBOM per platform. Shell completions, building from source and more are in INSTALL.md.

Part of the MKLab toolbox

honk is one of a family of small, sharp command-line tools from MKLab: ailloy (vendor-flexible AI for Rust tools), cosq (query Azure Cosmos DB), deemer (AI-judged integration tests), mdeck (Markdown presentations), pidge (e-mail and calendar for your AI agent) and rigg (configuration as code for Azure AI Search and Microsoft Foundry).

License

MIT