A curses front-end for various audio players
Branch: master
Clone or download
Pull request Compare This branch is 356 commits ahead, 144 commits behind andreasvc:master.
Type Name Latest commit message Commit time
Failed to load latest commit information.
.tx add transifex config Mar 27, 2015
.gitignore Add -s flag to save/recover state Oct 3, 2015
ChangeLog bump version to 2.4.1 Apr 19, 2018
LICENSE 1.46 Feb 28, 2011
MANIFEST.in also include .po files in distribution Jun 15, 2014
cplay.1 Add -s flag to save/recover state Oct 3, 2015
setup.cfg update coverage config Oct 4, 2015
setup.py drop unused argparse dependency Apr 19, 2018
tests.py fix tests Aug 6, 2017



cplay-ng is a curses front-end for various audio players written in python. It aims to provide a power-user-friendly interface with simple filelist and playlist control.

The original cplay is no longer maintained. This fork aims to maintaining the original code as well as keeping it up to date with recent developments (e.g. python3) and adding new features.


  • python
  • pyalsaaudio (optional) For Alsa mixer support
  • python-oss (optional) For OSS mixer support
  • pulseaudio-utils, specifically the pactl command (optional) For PulseAudio mixer support
  • mutagen (optional) For metadata support (IDv3 etc.)

For playback, install one or more of the following players:


pip install cplay-ng


cplay-ng [ file | dir | playlist ] ...

For a full list of command line options, see cplay-ng --help. When in doubt about runtime controls, press 'h' for a friendly help page.

Apart from cplay-ng, this distribution also includes the program cnq-ng to remote-control a running cplay-ng.


If you would like to change options passed to the actual players just edit the BACKENDS list in the cplay-ng script or put the BACKENDS definition in either ~/.cplayrc or /etc/cplayrc. If one of these files is available, it is executed by cplay-ng before initialization.

Macros are defined using the MACRO dictionary, where the key is a key and the value is a string of cplay-ng input. For example, the following would make ,d delete tagged (or current) files:

MACRO['d'] = '!rm "$@"\n'

Note, there is currently no version control for the rc-file!


A playlist can contain URLs, but the playlist itself will have to be local. For mpeg streaming, splay is recommended.

It is also possible to pipe a playlist to cplay-ng, as stdin will be reopened on startup unless it is attached to a tty.

The shell command gets the full path of either all tagged items or the current item as positional arguments.