aboutsummaryrefslogtreecommitdiff
path: root/tts.sh
diff options
context:
space:
mode:
Diffstat (limited to 'tts.sh')
-rwxr-xr-xtts.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/tts.sh b/tts.sh
new file mode 100755
index 0000000..089ca33
--- /dev/null
+++ b/tts.sh
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+grep --line-buffered -F "[CHATTTS]"|grep --line-buffered -F "<"|while read line
+do
+ pitch=$(echo $line|awk -F"[<>]" '{print $2}'| sha256sum | grep -Eo "[[:digit:]]{2}" | head -n1)
+ msg=$(echo $line|sed 's/@#[A-Za-z0-9]\{6\})//g;s/^[^>]*>//')
+ echo $msg|espeak -p $pitch
+done