Hopefully the final entry to my mostly one-way conversation
One thing I miss is the nice new notifications that came with Jaunty, so I modified a script I found that wraps amixer and uses the notify-send command to ... er ... notify you:
Code:
#!/bin/sh
if [ $1 = 'up' ]; then
amixer set Master 3%+
elif [ $1 = 'down' ]; then
amixer set Master 3%-
elif [ $1 = 'tinyup' ]; then
amixer set Master 1%+
elif [ $1 = 'tinydown' ]; then
amixer set Master 1%-
elif [ $1 = 'mute' ]; then
amixer set Master toggle
else
echo "Unknown control command: $1" >&2
exit 1
fi
VOLUME=$(amixer sget Master | sed '/^ *Mono: /{s/^.*\[\(.*\)%\].*/\1/;p;};d;')
STATUS=$(amixer sget Master | awk '$2 == "Mono:" { print $NF; }')
if [ $STATUS = '[off]' ]; then
ICON=notification-audio-volume-muted
else
echo $VOLUME
if [ $VOLUME -eq 0 ]; then
ICON=notification-audio-volume-off
elif [ $VOLUME -lt 33 ]; then
ICON=notification-audio-volume-low
elif [ $VOLUME -lt 66 ]; then
ICON=notification-audio-volume-medium
else
ICON=notification-audio-volume-high
fi
VOLUME="${VOLUME}%"
fi
notify-send "Volume" -i $ICON -h int:value:$VOLUME -h string:x-canonical-private-synchronous:
Just save the code and make it executable - I saved it to a file called 'VolChange' in my home folder.
Then in the compizconfig-settings-manager command section, I set the command for Volume Up to the following:
Similarly, I changed the Volume Down command but with 'down' at the end. I have also added a 'tinyup' and 'tinydown' that alters the volume by 1% and assigned it to ctrl+Volume Up/Down for when you want small changes
Bookmarks