#!/bin/sh
#
# Prepend your (log) lines with a timestamp
#
PREFIX=${1-"[%H:%M:%S]"}
while read line
do
  echo `date "+$PREFIX"` $line
done
