Skip to content

Instantly share code, notes, and snippets.

@rafaelvasco
Created July 14, 2025 17:45
Show Gist options
  • Save rafaelvasco/d80e7d8293dfe38be4b5fe93bb72c061 to your computer and use it in GitHub Desktop.
Save rafaelvasco/d80e7d8293dfe38be4b5fe93bb72c061 to your computer and use it in GitHub Desktop.
Convert all .cue/.bin files recursively (max 4 levels deep) to compressed CHD files using CHDMAN
#!/bin/bash
# Find .cue files up to 4 levels deep
find . -maxdepth 4 -type f -name '*.cue' | while read -r f
do
name=${f%.cue} # Remove '.cue' from the file name
chdman createcd -i "$name.cue" -o "$name.chd" --force
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment