diff options
Diffstat (limited to 'util/bin/mic.stt')
-rwxr-xr-x | util/bin/mic.stt | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/util/bin/mic.stt b/util/bin/mic.stt new file mode 100755 index 00000000..9236f85c --- /dev/null +++ b/util/bin/mic.stt @@ -0,0 +1,12 @@ +#!/bin/sh +set -efux +cd $(dirname $(readlink -f $0)) +. ../lib/stt/google.sh +duration=${1?please provide duration via \$1} +lang=${lang:-de-DE} +export lang +echo "language is set to $lang" +echo "will record for '$duration' seconds" +f=$(record_audio ${duration}) +trap 'rm $f' TERM EXIT HUP +stt "$f" |