Linux: Batch Convert RAW to JPG or PNG

Batch conversion of RAW images (e.g. Canon CRW og Nikon NEF) to JPEG

Get da stuff:

sudo apt-get install dcraw netpbm

Descend into directory containing the raw files, say they're Canon RAW images called xxxxxx.CRW and you want JPEGs:

for filename in *.CRW ; do dcraw -c -w "$filename" | pnmtojpeg > "$filename.jpg" ; done

...or if you're a Nikon guy/gal (aren't we all, really? Deep inside?), and you want PNGs (yes we do! And we want them now!):

for filename in *.NEF ; do dcraw -c -w "$filename" | pnmtopng > "$filename.png" ; done

**** THE END ****