How to create an applescript for multiple dd terminal commands in sequence (for multiple USB Drives duplication)
You can do this with a bash script.

#!/bin/bash

SOURCE="/Users/username/Desktop/source.img"

dd if=$SOURCE of=/dev/rdisk1 bs=1m
dd if=$SOURCE of=/dev/rdisk2 bs=1m
dd if=$SOURCE of=/dev/rdisk3 bs=1m
dd if=$SOURCE of=/dev/rdisk4 bs=1m
dd if=$SOURCE of=/dev/rdisk5 bs=1m
dd if=$SOURCE of=/dev/rdisk6 bs=1m
dd if=$SOURCE of=/dev/rdisk7 bs=1m

osascript -e 'display notification "Drives complete" with title "Complete!"'


Make the file executable (once):

chmod +x ~/Desktop/script.sh


Run it with administrative privileges:

sudo ~/Desktop/script.sh