Files
rhvoice-english/install.sh
2025-12-07 02:53:39 -05:00

36 lines
800 B
Bash
Executable File

#!/usr/bin/env bash
# Install RHVoice English pronunciation fixes
set -e
# Check if running as root
if [[ $EUID -ne 0 ]]; then
echo "Error: This script must be run as root (use sudo)" >&2
exit 1
fi
# Define paths
dictDir="/etc/RHVoice/dicts"
sourceDir="English"
# Verify source directory exists
if [[ ! -d "$sourceDir" ]]; then
echo "Error: Source directory '$sourceDir' not found" >&2
exit 1
fi
# Create dictionary directory if it doesn't exist
mkdir -p "$dictDir"
# Copy English pronunciation fixes
echo "Installing English pronunciation fixes to $dictDir..."
cp -rv "$sourceDir" "$dictDir/"
echo "Installation complete!"
echo "You may need to restart applications using RHVoice for changes to take effect."
echo "For example:"
echo "sudo killall speech-dispatcher"
exit 0