Show HN: Chimed – wind chimes in your Linux environments

(github.com)

4 points by drybjed a day ago | 0 comments

Have you ever played a game or watched a TV show/movie where certain actions like button presses or other events produced different sounds? This is usually done for audience's benefit (more action on screen) or in a game, to enforce the game loop. I wondered if sound effects could be useful in a work environment, in my case `vim`, to influence my brain in a similar way a game loop does things, and make working more "interesting" than procrastination. So I wrote 'chimed', a Python daemon that lets me play sounds on command and added `autocmd` options in `vim` to play sounds when entering/leaving Insert mode or command line, adding text, yanking, etc.

The idea is simple - load small `.wav` files into memory to make latency as small as possible and play them when certain events occur on inputs (and learn how daemons work in Python). Currently the only input is a FIFO, daemon expects specific configurable strings and plays a set of sounds found on https://freesound.org/. This could be expanded in the future to inputs over UDP or TCP, I had also an idea to create a set of process threads which could listen for certain interrupts and play a specific sound, like a set of "bells" in a "wind chime", which could be activated randomly. I'm sure many more ideas could be implemented later.

You can find `chimed` on GitHub, it's also available on PyPI as `chimed`.[1] I tested the installation using `pipx` in a clean Debian Bookworm environment, but if there are issues with installation please let me know in the comments. To integrate it with `vim` you can use an example configuration file [2]. See the README.md file for more details.

[1]: https://pypi.org/project/chimed/0.1.0/

[2]: https://github.com/drybjed/chimed/blob/master/lib/vim/vimrc