01 #!/usr/bin/env ruby
02
03 require 'rubygems'
04 require 'applescript'
05
06 AppleScript.execute("set volume #{ARGV[0]}")
update 2008/8/3
the way using applescript interpreter is $ osascript -e "set volume [1-7]"
or call in script by shebang.
01 #!/usr/bin/osascript
02
03 set volume [1-7]
No comments:
Post a Comment