Path: utzoo!attcan!uunet!lll-winken!ames!pasteur!ucbvax!hplabs!hpfcdc!rml From: rml@hpfcdc.HP.COM (Bob Lenk) Newsgroups: comp.unix.questions Subject: Re: Re: csh -> Bourne conversion Message-ID: <5740037@hpfcdc.HP.COM> Date: 24 Jan 89 22:13:15 GMT References: <571@island.uu.net> Organization: HP Ft. Collins, Co. Lines: 16 > $ date=`date +%d-%h-19%y` > > Actually, this brings up a point that programmers everywhere should > start thinking about: all of those hardcoded "19"'s in programs are going to > be useless in the year 2000. Think of all the shell scripts/programs > like the command above...perhaps using a variable or adding a format > to the date command (I notice that 'Y' isn't being used...a quick patch > to date would make it so that 'Y' would give you all four digits) would be > better, such as "date +%d-%h-$CENTURY%y" or "date +%d-%h-%Y". The current draft of the IEEE 1003.2 standard specifies %Y as giving the year with century. Bob Lenk hplabs!hpfcla!rml rml%hpfcla@hplabs.hp.com