#!/bin/sh
# Script for volume control
# 
# Accepts either a number and a +,- operator (volctl 5 +) or "toggle" (volctl toggle)

# If the lone argument is "toggle", toggle mute/unmute
[ "$1" = "toggle" ] && amixer -q sset Master toggle && signal-vol && exit

num=$1
dir=$2

amixer -q sset Master $num%$dir unmute && signal-vol