Skip to content

Instantly share code, notes, and snippets.

@lattera
Created August 11, 2015 18:11
Show Gist options
  • Save lattera/11bea1b266f728f0daf6 to your computer and use it in GitHub Desktop.
Save lattera/11bea1b266f728f0daf6 to your computer and use it in GitHub Desktop.
#!/usr/local/bin/zsh
amt="${1}"
if [ -z "${amt}" ]; then
echo "USAGE: ${0} [+-]amt"
exit 1
fi
mixer vol ${amt}
res=${?}
if [ ${res} -eq 0 ]; then
killall -USR1 i3status
else
i3-nagbar -t warning -m "Could not set volume. mixer exited with status: ${res}"
fi
exit ${res}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment