Announce the time on the hour?

You could use your crontab

  1. Create a little script

    mkdir -p ~/bin
    nano ~/bin/say_hour
    

    add the code below

    #!/usr/bin/env bash
    my_date=$(date +'%H:%M:%S')
    padsp espeak "$my_date"
    

    and set executable rights

    chmod +x ~/bin/say_hour
    
  2. Edit your crontab via

    crontab -e
    

    and add the configuration below

    0 * * * * bin/say_hour
    

You can replace the espeak line with one of the possibilities below

sudo apt-get install espeak
espeak $(date +"%H:%M:%S")
espeak $(date +%T)

# Adjust speed with `-s`, in words per minute, default is 160
espeak -s 10 $(date +"%H:%M:%S")

or

sudo apt-get install festival
date +"%H:%M:%S" | festival --tts
date +%T | festival --tts

or

sudo apt-get install speech-dispatcher
spd-say $(date +"%H:%M:%S")
spd-say $(date +%T)

# Adjust speed with  (-100 .. 0 .. 100)
spd-say -r -50 $(date +%T)

  • %I – hour (01..12) format
  • %H – hour in (00..23) format
  • %M – minute (00..59)
  • %S – second (00..60)
  • %THH:MM:SS in 24 Format

More options via man date, man espeak, man festival and man spd-say


This gives you the time in speech (thanks to kos for providing better syntax) :

First install say , which is found in gnustep-gui-runtime:

sudo apt-get install gnustep-gui-runtime

Then run it.

24-hour mode:

say "$(date +%R)"

12-hour mode

say "$(date +%I:%M%p)"