The mplayer
media player can be used to play files in a random order using the -shuffle
option. The -shuffle
option randomly selects files from a given list of files and plays them in the order specified by the random selection.
Here’s an example of how you can use the -shuffle
option to play a list of audio files in a random order:
mplayer -shuffle *.mp3
This command will play all the .mp3
files in the current directory in a random order.
Note that mplayer
will only shuffle the files once, and will not change the order of playback during the course of the session. To continuously shuffle the files, you will need to stop and restart the mplayer
session with the -shuffle
option.