Converting chiptunes to ogg

Use xmp to play the chiptune to stdout as wav,
boost the volume with sox (if needed),
encode it with oggenc

1
xmp -d wav -c filename.mod | sox -v1.5 -t wav - -t wav - | oggenc -o filename.ogg -

or if you want to convert all chiptunes in a directory:

1
2
3
for i in *.mod *.xm; do
    xmp -d wav -c $i | sox -v1.5 -t wav - -t wav - | oggenc -o ${i%.*}.ogg -
done