yquake2remaster/stuff/cdripper.sh

23 lines
514 B
Bash
Raw Normal View History

2012-04-29 13:57:33 +00:00
#!/bin/sh
# simple script that rips CDs to a format useable by Yamagis Quake2 client
# Needs cdparanoia and oggenc, useable with Quake II and both addons.
2009-10-06 15:41:04 +00:00
# Create directory
2012-04-29 13:57:33 +00:00
mkdir music
cd music
2009-10-06 15:41:04 +00:00
2012-04-29 13:57:33 +00:00
# rip all tracks beginning with second one (the first track is data)
cdparanoia -B "2-"
2009-10-06 15:41:04 +00:00
2012-04-29 15:12:15 +00:00
for I in track*.cdda.wav; do
NUM="${I#track}"
NUM="${NUM%.cdda.wav}"
oggenc -q 6 -o "$NUM.ogg" "$I"
2012-04-29 13:57:33 +00:00
done
2009-10-06 15:41:04 +00:00
2012-04-29 13:57:33 +00:00
# remove .wav files
rm *.wav
2009-10-06 15:41:04 +00:00
2012-04-29 15:11:21 +00:00
echo '
Ripping done, move music/ directory to /your/path/to/quake2/game/music/'