#!/bin/sh # # /usr/bin/viavoice # Restore alsa mixer settings for ViaVoice and start dictation # # Volker Kuhlmann # 9, 10 Sep; 10 Dec 2001 # f= if alsactl 2>/dev/null; then if [ -r /etc/asound.conf.viavoice ]; then echo "Restoring mixer settings from /etc/asound.conf.viavoice" alsactl -f /etc/asound.conf.viavoice restore "$@" f=1 fi if [ -r $HOME/viavoice/alsa.conf ]; then echo "Restoring mixer settings from $HOME/viavoice/alsa.conf" alsactl -f $HOME/viavoice/alsa.conf restore "$@" f=1 fi else echo "Can't execute alsactl - unable to restore mixer settings." fi test -z "$f" && echo \ "Can't find any mixer settings to restore, ViaVoice might not run too well." echo "" exec /usr/bin/vvstartdictation "$@"