Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- volume=$(osascript -e "get output volume of (get volume settings)")
- muted=$(osascript -e "get output muted of (get volume settings)")
- if [[ $volume -lt 30 ]]; then
- osascript -e "set volume output volume 30"
- fi
- afplay ~/snd/$1.mp3
- osascript -e "set volume output volume $volume"
- osascript -e "set volume output muted $muted"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement