marcosgaming Posted November 18, 2022 Posted November 18, 2022 Hi, i have a lot og games Xbox Classic in ISO and Xemu support only XISO image. I find 2 ways for conversion. 1) extract-xiso.exe + .\extract-xiso.exe -c .\folder's name 2) Rebuild an ISO (XISO) with XDVDMulleter This 2 ways are works fine but the second way it's more fast because convert directly ISO Game in ISO XISO for emulator XEMU. My problem ??????? I Would do this conversion massive for all games, so later i can import my collection dream in LaunchBox. Anyone can help me ??? I think that exists any batch command for to all this in just a few clicks Thanks for all. Mark. Quote
{c}Guy123 Posted September 18 Posted September 18 Here's a bash script that finds all .zip files in a folder, then converts them to xiso format, placing them in the folder above where the zip files are. Just put this script into the folder where you're iso's that need converting are and run it. It'll unzip them, convert them and put the completed xiso's up one folder. Enjoy! #!/usr/bin/env bash set -euo pipefail # === CONFIG === # Directory to search for .zip files (default: current directory) SRC_DIR="${1:-.}" # === REQUIREMENTS CHECK === command -v unzip >/dev/null 2>&1 || { echo "Error: unzip is required."; exit 1; } command -v dd >/dev/null 2>&1 || { echo "Error: dd is required."; exit 1; } # === MAIN === # Find all .zip files (case-insensitive), process each find "$SRC_DIR" -type f -iname '*.zip' -print0 | while IFS= read -r -d '' zip_path; do zip_dir="$(dirname "$zip_path")" zip_file="$(basename "$zip_path")" echo "==> Processing: $zip_path" # List entries that end with .iso (case-insensitive) inside the zip # We'll capture their relative paths (could include subfolders). mapfile -t iso_entries < <(unzip -Z1 "$zip_path" | awk 'BEGIN{IGNORECASE=1} /\.iso$/') # Unzip into the same directory as the .zip file echo "Unzipping into: $zip_dir" unzip -o -qq "$zip_path" -d "$zip_dir" if ((${#iso_entries[@]} == 0)); then echo "No .iso files found inside: $zip_file" continue fi # For each ISO that was in the zip, run dd as requested for rel_iso in "${iso_entries[@]}"; do iso_path="$zip_dir/$rel_iso" if [[ ! -f "$iso_path" ]]; then echo "Warning: expected ISO not found after unzip: $iso_path" >&2 continue fi iso_name="$(basename "$iso_path")" iso_stem="${iso_name%.*}" # Output ISO placed in the parent of the directory containing the ISO out_dir="$(dirname "$iso_path")/.." out_path="$out_dir/$iso_stem.iso" echo "Running dd on: $iso_path" echo "Output will be: $out_path" # Perform the dd with the exact parameters you specified dd if="$iso_path" of="$out_path" skip=387 bs=1M status=progress echo "Done: $out_path" done done echo "All done." 1 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.