Edit: Due to the fact that this article is old, the installation instructions may not work anymore. In order to successfully install the latest version of Sox, please access the nomacs tag and open the latest article (the one on top).
Hello Linux Geeksters. In this article I will show you how to install and use Sox (Swiss Army Knife of Sound Processing) on Ubuntu 13.10 Saucy Salamander, Ubuntu 13.04 Raring Ringtail, Ubuntu 12.10 Quantal Quetzal, Ubuntu 12.04 Precise Pangolin, Linux Mint 15 Olivia, Linux Mint 14 Nadia and Linux Mint 13 Maya.
Sox (Swiss Army Knife of Sound Processing) is a command line interface music player. So, you can play music directly from your terminal very easy with it, if you are good at using wildcards and bash completion.
I have installed this CLI Music player (even if I am a big fan of Audacious), to play music from the terminal, when connecting via putty from my Nokia N8 to my Linux System.
How to install Sox on Ubuntu and Linux Mint do:
$ sudo apt-get install sox libsox-fmt-all
Sox is the music player’s package and libsox-fmt-all is needed to enable mp3 playing on sox.
How to use sox:
Go to your music directory:
$ cd ~/Music
ls it, to see the song list (I prefer to use ls -1 for this):
$ ls -1
To play a song, type play song_name:
Use tab completion, unless you want to type for ages!!!
$ play Iron\ Maiden\ -\ Fear\ of\ the\ dark.mp3
To play all the mp3 files, type play *.mp3:
$ play *.mp3
To quit the application press Ctrl – C .
Note: if you have a lot of tracks in your music folder and play them with play *.mp3, you will need to Ctrl – C every song, in order to close the program.
Quiting Sox (after you have used play *.mp3) is actually difficult because sox is evil. Press Ctrl – Z to send the process in the background, get its PID and punch it with sudo kill -9 $PID.