This script automates the process of creating a shuffled playlist of complete albums for the Cmus music player. It groups songs by albums, shuffles the albums, and limits the playlist to a specified number of albums. The script then auto-imports this playlist into Cmus.
- Bash
- Awk
- Sed
- Cmus music player installed and configured
- Fetches the latest library from Cmus
- Groups songs by albums
- Shuffles albums randomly
- Limits the playlist to a specified number of albums (default is 10)
- Removes empty lines from the playlist
- Imports the shuffled playlist into Cmus
-
Clone this repository or download the script.
-
Open a terminal and navigate to the directory containing the script.
-
Make the script executable:
chmod +x your-script-name.sh
-
Run the script:
./your-script-name.sh
-
Open Cmus to see your new shuffled playlist of complete albums.
You can change the number of albums in the shuffled playlist by modifying the ALBUM_LIMIT
variable at the top of the script.
# Album limit
ALBUM_LIMIT=10 # Change this number to your preference
This script is released under the MIT License.