Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!lll-winken!uunet!munnari!otc!metro!physiol!daved From: daved@physiol.su.oz (Dave Davey) Newsgroups: comp.text Subject: Re: Time of Day in troff (and .TH in LaTeX) Summary: fdate not date ? Message-ID: <581@physiol.su.oz> Date: 11 Apr 89 01:31:55 GMT References: <16810@cos.com> <512@elan.UUCP> Organization: Physiology Dept., Univ. of Sydney, NSW, Australia Lines: 13 In article <512@elan.UUCP>, kg@elan.UUCP (Ken Greer) writes: > From article <16810@cos.com>, by duc@cos.com (Duc Kim Nguyen): > > > > (1) troff: how do I get time of day ? Similar to to get date from > Try this! > > .sy /bin/date +".nr hr %H%n.nr mi %M%n.nr se %S" > /tmp/date\n($$ > .so /tmp/date\n($$ > .sy rm -f /tmp/date\n($$ This will only work if your date program accepts the format argument, and will not be the case for most standard /bin/date programs. You might look for fdate.