summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xmodules/zeit8
1 files changed, 6 insertions, 2 deletions
diff --git a/modules/zeit b/modules/zeit
index 0b0537d3..340d6fce 100755
--- a/modules/zeit
+++ b/modules/zeit
@@ -5,10 +5,14 @@ case "$1" in
echo "say current time" ;;
(*)
exec >>$NOISE_linefeed
+ eval `date +'k=%k ; M=%M'`
+ M=`echo $M | sed 's/0*//'`
echo /set pitch 10
case "$lang" in
- (de|'') date +'"Es ist %k Uhr %M."' >$NOISE_linefeed ;;
- (en|*-en) date +'"It is %k o clock and %M minutes"' >$NOISE_linefeed ;;
+ (de|'') echo " Es ist $k Uhr $M" >$NOISE_linefeed ;;
+ (en|*-en)
+ test -z "$M" || M="and $M minutes"
+ echo " It is $k o clock $M" >$NOISE_linefeed ;;
(*) echo "Error: unsupported lang = $lang" >&2
esac
echo /set pitch ${noise_pitch-100}