Skip to content

Instantly share code, notes, and snippets.

@codyhanson
Created January 3, 2014 14:52
Show Gist options
  • Save codyhanson/8239123 to your computer and use it in GitHub Desktop.
Save codyhanson/8239123 to your computer and use it in GitHub Desktop.
Controls the volume on my old iMac
#! /usr/bin/perl
die "usage volume.pl NUMBER" if @ARGV == 0;
$vol = $ARGV[0];
$command = 'sudo osascript -e "set Volume ' . $vol .'"';
system($command);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment