[linux-audio-user] Re: best window manager for making music

From: Brian Dunn <job17and9@email-addr-hidden>
Date: Mon Mar 06 2006 - 01:09:50 EET

Thanks again, lau. You've help me sort through the bazillion options out
there and i'm now bedazzling myself with the glamor of fluxbox... so
fresh, yet so clean.
For a while i was frustrated by the absence of a good dockapp alsa
mixer, then i discovered the beauty of the .fluxbox/keys file. Mod4 +,
rear speakers louder. Mod4 -, rear speakers quieter. sweet.
amixer provides no mute toggle for rear out of an emu10k1. so i wrote
this goofy script and bound it to Mod4 m.

        # Check if the Wave Surround level is already 0
VOL=`amixer sget 'Wave Surround' | grep 'Front Left:' | cut --delimiter=' ' --fields=6`
if [ $VOL -gt 0 ]; then
        #mute
        #store the current wave surround volume in VOL
        LASTVOL=`amixer sget 'Wave Surround' | grep 'Front Left:' | cut --delimiter=' ' --fields=6`
        #turn the sound all the way down.
        amixer sset 'Wave Surround' 0
        echo $LASTVOL > ~/.lastvol
else
        #unmute
        amixer sset 'Wave Surround' `cat ~/.lastvol`
fi

is this like a really dumb way to add a mute toggle? This is like my
first real bash script, so any suggestions are welcome. Here i'll get
the ball rolling: i should learn to use sed or awk so i don't have to
pipe grep and cut together.

well, thanks to ya'll my computer is looking and sounding sweeter than
ever and it's oh so customized.

God Bless,
Brian
Received on Mon Mar 6 04:15:06 2006

This archive was generated by hypermail 2.1.8 : Mon Mar 06 2006 - 04:15:06 EET