Source: https://coderwall.com/p/nhp7mq/convert-raw-photos-to-jpg-in-the-mac-os-terminal
No need for slow and heavy Photoshop scripts for this one, you can do easily do this right from your terminal window.
This is possible using "sips", an image editing tool already available on Mac which allows you to do all sorts of image manipulation, including resizing and converting.
So we first grab all RAW files in a folder, We convert them to jpeg (or any other format),