#! /bin/sh
# $Header:date.sh 12.0$ 
# $ACIS:date.sh 12.0$ 
# $Source: /ibm/acis/usr/sys/dist/bin/RCS/date.sh,v $ 
#
# 5799-WZQ (C) COPYRIGHT IBM CORPORATION 1988
# LICENSED MATERIALS - PROPERTY OF IBM
# REFER TO COPYRIGHT INSTRUCTIONS FORM NUMBER G120-2083
#
uflag=0
case "$1" in
-u)
	uflag=1
	shift
	;;
esac
case "$#" in
0)
	exec /etc/syscall gettimeofday \&0 \&20 \; = \&0 ! 4 \; ctime \&0 \; printf %s \$ 
	;;
1)
	;;
*)
	echo "usage: date [-n] [-u] [yymmddhhmm[.ss]]"
	exit 1
	;;
esac

/etc/syscall gtime \'$1 $uflag \; = \$ + 0 90 \; settimeofday \&\$90 0 
rc=$?
/etc/syscall gettimeofday \&0 \&20 \; = \&0 ! 4 \; ctime \&0 \; printf %s \$ 
exit $rc
