Change System Volume from Command Line on Mac OS
Oftentimes the awesome GUI applications we love are simply gloss over a command line functionality. While I do love a visual app, it's always good to know how to do things from command line, if only for the sake of automation. I've covered loads of command line secrets, most notably Mac Camera Access, so I wanted to figure out if I could control volume from command line.
Change Mac System Volume
The secret to changing Mac system volume from command line is through
# Max volume
sudo osascript -e "set Volume 10"
sudo osascript -e "set Volume 0"
# 50% volume
sudo osascript -e "set Volume 5"
Values range from
0 (muted) to
10 (maximum volume). Note that you don't get to see a nice volume change indicator -- the volume simply changes without any feedback.
David asked me if I'd be up for a guest post picking out some of my favorite Pens from CodePen. A daunting task! There are so many! I managed to pick a few though that have blown me away over the past few months. If you...
attachEvent. Times have changed but there are still a few functions each developer should...
Remember the old days of DHTML and effects that were an achievement to create but had absolutely no value? Well, a trailing mouse cursor script is sorta like that. And I'm sorta the type of guy that creates effects just because I can.
One thing I love about love about Safari on the iPhone is that Safari provides a darkened background effect when you click a link. It's the most subtle of details but just enforces than an action is taking place. So why not implement that...