Control Volume on OS X from the Terminal

This is helpful if you need to control the volume on a Mac that you have access to via SSH, or need to control it with a bash script.

Basic syntax

sudo osascript -e "set volume (0-10)"

Turn volume off

sudo osascript -e "set volume 0"

Turn volume to 100%

sudo osascript -e "set volume 10"

Turn volume to 51%

sudo osascript -e "set volume 5.1"

 

Leave a Reply

Your email address will not be published. Required fields are marked *