bin/say @ acf4298ae9e5

Update subrepos
author Steve Losh <steve@stevelosh.com>
date Tue, 07 Nov 2023 10:02:24 -0500
parents 4f513bcec56a
children (none)
#!/usr/bin/env bash

# PREREQS:
#
#   sudo apt install festival festvox-us-slt-hts
#
# USAGE:
#
#   echo "The tea is ready." | say
#   say The tea is ready.

set -euo pipefail

function sayStdin () {
    festival --batch \
        '(voice_cmu_us_slt_arctic_hts)' \
        '(tts "-" nil)'
}

if [ "$#" -eq 0 ]; then
    sayStdin
else
    echo "$@" | sayStdin
fi